bobbysmith007
Forum Replies Created
-
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Related question about previous question."columnNameMap=>array('contest_id'=>'????', 'post_title'=>'????', 'name'=>'??', 'grade'=>'??', 'class'=> '?', 'title'=>'???', 'school'=>'???', 'address'=>'????', 'sender'=>'???', 'phone'=>'????', 'p_delivery'=>'???????', 'p_invoice_num'=>'????', 'pre_state'=>'??')"
That seems like a parse error (the double quote is at the very end). You should quote the key and not the array as follows:
"columnNameMap"=>array('contest_id'=>'????', 'post_title'=>'????', 'name'=>'??', 'grade'=>'??', 'class'=> '?', 'title'=>'???', 'school'=>'???', 'address'=>'????', 'sender'=>'???', 'phone'=>'????', 'p_delivery'=>'???????', 'p_invoice_num'=>'????', 'pre_state'=>'??')
Checkout the add_db_table_editor parameter columnNameMap
From the readme:
columnNameMap: A map of actual column names to displayed label, EG: columnNameMap=>Array(‘column_name’=>’Column Alias’);
Hope this helps, but let me know if you have trouble still
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Android/iPad editingThe problem definitely exists with the underlying software,which has no intentions of supporting touch devices :/ I activated jquery-ui-touch-punch which is supposed to help, but i still cant quite get the click to edit working. looking at a custom event handler
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Android/iPad editingI will look into this next week. I have a heavy work load currently, but your kind words and a donation are likely to help me get to this rapidly ??
Talk to you on Monday
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Android/iPad editingOk i cant edit in firefox, so at least I have a basis for testing. Thanks for the bug report.
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Android/iPad editingI have a sony xperia Z2 with the normal app store chrome on vanilla Android 5.1.1. I might try to install firefox or something.
Just to verify, you can edit cells on your desktop right?
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Android/iPad editingI havnt tried to do much on mobile devices, and any limitations here are likely slickgrid (the underlying spreadsheet software). That said I was able to double tap on a cell in chrome on my android to activate editing.
Hopefully this works everywhere and is sufficient ??
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Host install errorhrm… well The above links claim that Php 5.4 should be sufficient, but if you are getting a syntax error on importing the namespace, it would seem *something* must be wrong.
Line 8 and 9 are just importing the PHPSQL stuff so its easier to manipulate the queries being sent to the server.
#8 use PHPSQL\Parser;
#9 use PHPSQL\Creator;I am not sure what else to suggest as it has always worked for me.
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Host install errorMy guess would be that namespaces are not supported on your host due to a low version of php. Php must be 5.3 or above for namespaces. If you see that this is not the issue, please follow up.
https://stackoverflow.com/questions/6473126/namespaces-in-php-5-2
Forum: Reviews
In reply to: [WP-DB-Table-Editor] Thank you very muchThanks for contributing and for the nice review.
I have added a more correct example to the examples directory of the plugin. (You should probably not wp_register_script outside of an action).
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Displaying Zero Rowstfrancois:
The plugin displaying 0 rows is just a general sign of failure and doesnt point to any specific cause. You should enable wordpress debugging and database debugging (define(‘WP_DEBUG_DISPLAY’, true);define(‘WP_DEBUG’, true);) and look for error output on your page. You can also examine the javascript console and look for client errors.
Once you have found a specific error message and provided the configuration you are using to cause it, I can probably help you find the answer
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Quick Start – How I did itThanks for your post
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Disable the "Delete" optionYou can either enqueue a javascript with a lower priority that removes the button or add a style sheet that hides it. Currently if you can edit, you can delete (they are not separate).
Sorry for the late reply, I must have missed this.
Forum: Plugins
In reply to: [WP-DB-Table-Editor] Next step after installing and activating the plug in> “DB-Table Editor Interfaces are added by calling the add_db_table_editor function in your theme’s functions.php file. This supports wp_parse_args style arguments.”
If you are uncomfortable following that direction (and the rest of the readme), I fear this plugin maybe a bit much for you, as it assumes quite a bit of knowledge about php, sql and wordpress.
To answer your question directly though:
Each wordpress theme can contain a functions.php file that allows execution of arbitrary php before your theme is loaded. Inside of that file you will need to call the
add_db_table_editor(Array('table'=>'my_table'...))
filling in all the arguments (as described in the readme). You will probably want to wrap all calls to add_db_table_editor inif(function_exists('add_db_table_editor'))
incase you ever deactivate the plugin (examples in the readme).Hope this helps,
Cheers,
RussForum: Plugins
In reply to: [WP-DB-Table-Editor] Is this possibleWhat do these menues have to do with this plugin? wp-db-table-editor doesnt create those menues, so you must be doing it yourself or another plugin is responsible. As far as I know using
add_menu_page
,add_submenu_page
and theremove
versions of those two functions, you should be able to create any menu structure you want. I cant debug your application for you though (especially without the code).It sounds like maybe you have the
menu_slug
for both menus set to the same value or something.Cheers,
Russ