Viewing 8 replies - 1 through 8 (of 8 total)
  • I too am having problems with Post Tabs and qtranslate.

    See screenshots at:

    Normal (untranslated version): https://www.kinnersleydrake.co.uk/FibreFab.png

    Broken version with translation turned on: https://www.kinnersleydrake.co.uk/qtranslate-FibreFab.png

    This needs to be address ASAP as we are launching our new website next week and the hard work that has gone in to the translations is now defunct.

    It appears WPT does not support the rewritten URLs that qTranslate can be setup with. I also had a problem when I was using the default pre-path URL (e.g., /es/page). It seemed to load the page on top of another. I have not tested with the two other qT URL mod options but those may work fine.

    The fix for me was to update line 236 of wordpress-post-tabs.php. Replace REQUEST_URI with REDIRECT_URL. So…

    Old
    $pageurl="https://" . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];

    New:
    $pageurl="https://" . $_SERVER['HTTP_HOST'] . $_SERVER['REDIRECT_URL'];

    It is obviously not a good idea to update a plugin directly. It was needed in my case and I hope the plugin creator notices this and adds the change.

    Both are great plugins.

    @anterys how have you set up qTranslate? Are there any other settings you’ve changed? We’re running with the pre-path too but I’ve tried changing the code that you mentioned but this still doesn’t seem to help

    My qT setup is pretty much out of the box. I changed around the languages only.

    I did a quick Google search and found that this server variable is not available on all servers or it is the same as REQUEST_URI. In my case, it returned the very important prepended URL (e.g., “/es/…”). You may try to output all the server variables while on the page with the post tabs and see which one produces the correct URL string.

    The other option, which will certainly fix your code but is a much less scalable solution is to use the qtrans_getLanguage() function in the post tabs plugin. This has the obvious disadvantage of linking the two plugins.

    $pageurl = function_exists( 'qtrans_getLanguage' ) ? "https://" . $_SERVER['HTTP_HOST'] . "/" . qtrans_getLanguage() . $_SERVER['REQUEST_URI'] : "https://" . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];

    Something like the above might work. I haven’t tested it by the way.

    @vincepettit I′m having the same problem… any updates??? thanks!

    Anterys 1st solution worked for me just perfect. many thanks!!! I had the exact same issue (one page over the other) but by altering line 236 on wordpress-post-tabs.php worked like a charm! Did not check his 2nd option since its fine with me the 1st one.

    It is strange that this has not been resolved up to now!

    Good to hear @johnravrasta. I have not had any issues with this fix so do not know the status of the plugin @mariosm18.

    Thank you so much anterys. It works fine for me too.
    It’s time for the devpers of the plugin to correct the issue.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘[Plugin: WordPress Post Tabs] conflict with "qtranslate"’ is closed to new replies.