• Resolved segelstrom

    (@segelstrom)


    I am cross-posting this Support-questions on Responsive and TablePress forums

    Hi,
    I am currently rebuilding the website of a small academic conference I am involved in. I am building it as a child theme on Responsive Theme and am using TablePress to build a sortable archive over previously published papers in earlier editions of the conference. So far so good.

    However, during one of the later updates of the two plug-ins one has done some change which makes it not play nice with the other anymore. The table shows as it should, reads it CSS and so on. However, the javascript doesn’t work – that is, no sorting and no searching which were the main reasons I opted for this plugin. When I first installed the two plugins several months ago the javascript did work. Since then I updated both as well as wordpress to the latest versions and now the javascript part doesn’t work anymore.

    As the site isn’t live yet and I am building a new theme on the new web page I can’t provide a link, but when I change the theme displayed (with the help of this plugin) I notice the problem is linked to Responsive and TablePress somehow. Neither the child theme nor the original Responsive theme display the javascript-parts of the table, but all my other installed themes do so. I even added the wp_footer()-function in my child theme as it isn’t in the normal Responsive-them, but to no avail.

    Any ideas?

    https://www.ads-software.com/extend/plugins/tablepress/

Viewing 14 replies - 1 through 14 (of 14 total)
  • Not really sure if this is related to Responsive and leaving the topic to the plugin author. If it turns out that there’s something with the Theme, please let me know.

    Thanks,
    Emil

    Plugin Author Tobias B?thge

    (@tobiasbg)

    Hi,

    thanks for your post.

    Judging from your description, this is likely a conflict between the JavaScript codes of the theme and the DataTables library that TablePress uses.
    To confirm this, I’d need to take a direct look at the page. Unfortunately, as you say, you can’t provide a link, so I guess, you’ll have to try to debug this yourself: Please check if there are any JavaScript errors in the browser console, with the help of https://codex.www.ads-software.com/Using_Your_Browser_to_Diagnose_JavaScript_Errors

    Regards,
    Tobias

    Thread Starter segelstrom

    (@segelstrom)

    Hi Tobias and Emil,
    and thanks for your answers. By going through the steps suggested by Tobias there seem to be a few errors originating from the Responsive theme as in this screenshot: https://servdes.org/javascripterrors.jpg

    Regards,
    Fabian

    Plugin Author Tobias B?thge

    (@tobiasbg)

    Hi Fabian,

    thanks for investigating this.

    The reason for this issue is tricky, and it’s not really the fault of the Responsive theme, although the theme will need a change in the future.
    The source of this problem is the jQuery JavaScript library. That library got an update (to version 1.9) recently, and in that library, a few things (like browser detection) where removed (or better: Moved to another JS library).
    WordPress and probably all themes are however developed using jQuery 1.8.3, which is also shipped with WordPress.
    On your site however, there’s very likely a plugin installed that loads jQuery from the Google CDN network, and always requests the latest version of jQuery. And that’s what breaks the JS.

    You should therefore try to find the plugin (I can not really imagine that the theme does this) that is responsible for loading jQuery from the Google CDN. You should then change that to only load version 1.8.3, or remove it entirely (which I’d actually recommend).

    The theme developer of the Responsive theme should start testing the theme with jQuery 1.9. (Although WordPress 3.6 will come with jQuery 1.9 AND that extra compatibility library that I mentioned).

    Regards,
    Tobias

    Thread Starter segelstrom

    (@segelstrom)

    Tobias,
    thanks a lot for your engaged comments! And sounds like the issue will hopefully be resolved with the next set of updates. If I’m really lucky they will arrive before the new site is launched, otherwise we’ll get the search and sort as bonus features in a not to distant future ??

    Plugin Author Tobias B?thge

    (@tobiasbg)

    Hi,

    sure, no problem, you are very welcome!

    This is however not really about TablePress or its features! This is a problem with something else on your site, and you should get it fixed.

    I really recomment that you try to find which plugin is responsible for loading jQuery from the Google CDN. Otherwise, this will only be fixed if the theme author really makes the theme compatible with jQuery 1.9. (Note that he doesn’t really have to, as the theme will work fine for all people who are not loading jQuery from the Google CDN.)
    This is your only choice, as there’s nothing that I can do about this in TablePress.

    Regards,
    Tobias

    Thread Starter segelstrom

    (@segelstrom)

    Yup, I’ve realised that too. Will try to continue digging deeper into the issue although I have to admit that I am really at the edge of my knowledge here. Resorting to ctrl+x, ctrl-s, f5 –> see what happens –> ctrl+z to return to original state. Wouldn’t have got as far as that without your help!

    Plugin Author Tobias B?thge

    (@tobiasbg)

    Hi,

    the best way is to deactivate all plugins (except TablePress) one by one and check when the line similar to

    <script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>

    in the HTML source of a page changes to something like

    <script type='text/javascript' src='https://www.servdes.org/wp-includes/js/jquery/jquery.js?ver=1.8.3'></script>

    Once that changes, you have found the plugin that is responsible for loading jQuery from the Google CDN.

    Regards,
    Tobias

    Thread Starter segelstrom

    (@segelstrom)

    And there I found a solution to my problem as well. In case anyone has followed the thread and is interested, I posted it over at the Responsive forum: https://themeid.com/help/discussion/5139/tablepress-and-responsive-child-javascript-issues#Item_3

    Plugin Author Tobias B?thge

    (@tobiasbg)

    Hi,

    nope, that’s also not a real solution. It’s just a work around that leads to the TablePress JS being executed before the theme’s JS. Due to that, the error just happens later, but it happens.
    You should really try to find the plugin that is loading jQuery from the Google CDN.

    Regards,
    Tobias

    Thread Starter segelstrom

    (@segelstrom)

    Plug-in found and “error” reported on their Support-forum. Doesn’t look like the author is active there though ??

    Thanks again Tobias!

    Plugin Author Tobias B?thge

    (@tobiasbg)

    Hi,

    I don’t think that it is “Mail Subscribe List” that is doing this. There’s no reference to jQuery in its source code.
    It must be another plugin.

    Regards,
    Tobias

    Thread Starter segelstrom

    (@segelstrom)

    You’re right. I had deactivated another one because it wasn’t in use before starting my testing. After rechecking based on your comment it turns out it was that one; https://minitwitter.webdevdesigner.com/

    Plugin Author Tobias B?thge

    (@tobiasbg)

    Hi,

    yeah! That’s the plugin that was causing this! Great that you found it!

    In fact, from what I can see, the author was already aware of the problem and added a change to the plugin. Upgrading to the latest version 1.4.1 should fix all of your issues. ??

    Best wishes,
    Tobias

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘TablePress and Responsive Theme’ is closed to new replies.