Hi,
thanks for your post. You are correct, as these are not regular WordPress plugins, they are installed differently.
As a start, I suggest to read http://www.datatables.net/blog/Getting_started_with_DataTables%3A_First_steps, and then the instructions for each plugin.
Regarding the files, you can just put them into a new folder, e.g. in your wp-content dir. You might then just need to adjust the URLs later in the code.
Additionally, my recommendation is to invoke these plugins manually. That means: Turn off the usage of DataTables for your table in WP-Table Reloaded, and load everything manually (by following those instructions from above). That way, WP-Table Reloaded will only deliver the HTML code of your table. A useful plugin to add JavaScript code only to certian posts/pages is the HiFi plugin (http://ww.wp.xz.cn/extend/plugins/hifi/).
Regards,
Tobias
Hi –
I would like to use a plug-in called Audio Player in my table cells. This plugin generates a shortcode that creates an instance of an embedded player for an MP3 audio file. When I tried putting the shortcode in the table cell, it was just echoed as plain text. Is there a way to make it work?
Regards,
– Tom
Hi Tom,
thanks for your question.
Yes, you can use Audio Player in table cells. It just requires some small extra work because the Audio Player plugin does not use regular WordPress Shortcodes, but its own version – which do not work out of the box in tables.
You can easily make them work by adding the following line of code to the file “functions.php” of your theme.
add_filter( 'wp_table_reloaded_cell_content', 'insert_audio_player' );
Best wishes,
Tobias
Thanks, Tobias. I dropped in the filter, but it seemed to wipe out the table structure. All the text in the table just ran together. Is there something more I need to add to the functions.php file? Or is there something I need to set on the table to make sure it accommodates the player?
Regards,
– Tom
Hi Tom,
no, usually you don’t need anything else.
But can you maybe post the URL to the page with the table, so that I can take a look and maybe find out why it is not working?
Regards,
Tobias
Hi Tobias –
http://www.aliveinthenow.com/show/show-schedule/
Here is the URL for the page with the table. What appears to happen is that the player gets inserted way down the page and everything gets pulled out of the table and placed above it. Then a blank table structure is displayed below the player.
Thanks for taking a look at it,
– Tom
Hi Tom,
thanks for the URL.
I think I found out what’s wrong. Please try again with this code in the functions.php
add_filter( 'wp_table_reloaded_cell_content', array( &$AudioPlayer, 'processContent' ), 2 );
The code in my first answer correct (as I just saw, the function echoes its return value instead of just returning it, which is necessary). The new code should behave correctly 🙂
Best wishes,
Tobias
Perfect – worked like a charm! Thanks, Tobias!
Hi,
no problem, you are very welcome!
Best wishes,
Tobias