• Resolved candreu

    (@candreu)


    I have a problem with Thickbox and W3 Total Cache. When I active the minify JS, Thickbox doesn’t work. I tried Auto Thickbox and Auto Thickbox Plus, and both have the same problem. Is there any way to active minify JS with Thickbox?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Are you using “Auto” Minify mode? (check W3TC General Settings in the Minify section) If so, try disabling Minify and clearing W3TC cache to see if this fixes Thickbox. If Thickbox is fixed, try “Manual” Minify mode.

    Auto Minify combines all javascript files it finds into one file. Some scripts won’t work as intended when combined.

    Manual Minify allows you to choose which CSS and JS files to combine.

    Hi candreu,

    I’m the author of Auto ThickBox Plus plugin.

    I have a problem with Thickbox and W3 Total Cache. When I active the minify JS, Thickbox doesn’t work. I tried Auto Thickbox and Auto Thickbox Plus, and both have the same problem.

    I tested W3 Total Cache with ThickBox, and found the following error has occured.

    Uncaught ReferenceError: thickboxL10n is not defined (thickbox.js)

    thickbox.js output the <script> tag before the closing <body> tag like bellow.

    <script type='text/javascript'>
    /* <![CDATA[ */
    var thickboxL10n = {"next":"Next >","prev":"< Prev","image":"Image","of":"\/","close":"Close","noiframes":"This feature requires inline frames. You have iframes disabled or your browser does not support them.","loadingAnimation":"http:\/\/example.com\/wp-includes\/js\/thickbox\/loadingAnimation.gif","closeImage":"http:\/\/example.com\/wp-includes\/js\/thickbox\/tb-close.png"};
    /* ]]> */
    </script>
    <script type="text/javascript" src="http://example.com/wp-includes/js/thickbox/thickbox.js?ver=3.1-20111117"></script>
    

    W3 Total Cache combines only <script src=""> tag. I think that text data inside <script> tag should be combined.

    Anyway, I modified Auto ThickBox Plus to be compatible with W3 Total Cache. Please reinstall latest version and try it after you empty caches.

    Thread Starter candreu

    (@candreu)

    Thank you, attosoft. I will update Auto ThickBox Plus and I retry to minify JS.

    Thread Starter candreu

    (@candreu)

    Sorry, but I updated Auto Thickbox Plus and it doesn’t work with W3 Total Cache yet. I get the same error about thickboxL10n.

    Oh, I’m sorry. I updated thickbox.js but forgot to update thickbox.min.js.
    Please retry (delete and install) latest version.

    Thread Starter candreu

    (@candreu)

    Now it’s right. Thank you!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Thickbox doesn't work with W3 Total Cache’ is closed to new replies.