• Hello,

    I have a table of companies, and would like to add the current stock price. Is this possible?

    Thanks.

    Impressive plug-in by the way.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter Peter Brock

    (@peter-brock)

    When I wrote “the current stock price”, I meant an automatically updating price.

    Thread Starter Peter Brock

    (@peter-brock)

    Another piece of the puzzle is the plugin called “Stock Quotes” by Dagon Design. This plugin uses short codes, but when I enter a short code into a cell, it doesn’t grab the price. Instead I see the short code itself [stock AAPL].

    Thread Starter Peter Brock

    (@peter-brock)

    Here’s the link to the plugin

    http://www.dagondesign.com/articles/stock-quotes-plugin-for-wordpress/

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    automatically updating (and storing) of data inside a table is not possible. The plugin was designed to hold and show static data and is not suited very well for dynamic data.
    That means, that you could still achieve what you need with other means, where you already mention one with Shortcodes. (The other possibility would be to directly use PHP code in the cells, for which you first need an Extension from my website.)
    With those methods, the code would need to deliver the dynamic data when the page is rendered. With that, the actual data is however not stored in the table (just the Shortcode is).

    To make your mentioned Shortcode work, you’ll likely need to add a tiny piece of code. Reason for that is, that the Shortcodes you mention are not regular WordPress Shortcodes (i.e. they don’t use the WordPress Shortcode API but a custom implementation). While regular WordPress Shortcodes work out of the box, that mentioned tiny modification is necessary to make custom-developed Shortcodes word. Fortunately, that is not too hard to achieve. For the “Stock Quotes” plugin, just add the following line of code to the “functions.php” file of your theme (within the PHP brackets):

    add_filter( 'wp_table_reloaded_cell_content', 'ddsq_process' );

    Best wishes,
    Tobias

    Thread Starter Peter Brock

    (@peter-brock)

    Thanks Tobias,

    I added the filter to my functions.php file and it works beautifully.

    To thank you for your help, I sent a donation.

    Keep up the good work.

    Peter

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi Peter,

    great to hear that this worked 🙂 And also thanks a lot for your donation, that is very kind!

    Regards,
    Tobias

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘[Plugin: WP-Table Reloaded] Stock quotes’ is closed to new replies.