WordPress.org

Forums

Autoptimize
[resolved] youtube resize problem with autoptimize and WP Super Cache (13 posts)

  1. blau
    Member
    Posted 2 years ago #

    I use a wp theme that has a "magazine style" layout in the home page. When posting a youtube video, the video it is not resized to fit the available space, overlapping other content areas.

    This only happens using both Autoptimize and WP Super Cache together. Using either alone is fine. You can see the issue here:

    http://nazioneindiana.bamaulion.net/

    I don't know if it's an autoptimize or wpsupercache issue, or a theme issue. I just deactivated Autoptimize to get along.

    Autoptimize 1.5.1
    WP Super Cache 1.2
    Magazine Premium Theme 1.1.9.3 http://themes.bavotasan.com/2010/magazine-premium/

    http://wordpress.org/extend/plugins/autoptimize/
    http://wordpress.org/extend/plugins/wp-super-cache/

  2. Frank Goossens
    Member
    Plugin Author

    Posted 2 years ago #

    Based on what I see, the theme does some jQuery-magic to resize video's (which is in the aggregated javascript that is loaded near the end of the HTML). Not exactly sure what the reason is, but it seems jQuery isn't loaded, so the resizing-code is not triggered.

    Can you try the following:

    1. disable "Optimize JavaScript Code?" in Autoptimize config. Does that fix the problem? Re-enable after the test (and clear WP Super Cache cache) and then;
    2. enable the "Look for scripts only in <head>?" option in Autoptimize config. Does this fix the problem? Disable after the test (and clear WP Super Cache cache) and then;
    3. open /wp-content/plugins/Autoptimize/classes/AutoptimizeScripts.php and on line 7 add "jquery" to the "dontmove"-array. Does this fix the problem?
  3. blau
    Member
    Posted 2 years ago #

    Hello frutta,

    1 disable "Optimize JavaScript Code?" in Autoptimize config. Does that fix the problem?

    Yes.

    2 enable the "Look for scripts only in <head>?" option in Autoptimize config. Does this fix the problem?

    No.

    3 open /wp-content/plugins/Autoptimize/classes/AutoptimizeScripts.php and on line 7 add "jquery" to the "dontmove"-array. Does this fix the problem?

    No.

    Emptied autoptimized, wpsupercache and browser cache every time. Anything else i can do?

  4. Frank Goossens
    Member
    Plugin Author

    Posted 2 years ago #

    Weird. I'd like to propose you run without JavaScript optimization for the time being, at least your HTML and CSS will be Autoptimized that way.

    To find the reason for this bug (which seems pretty specific to the combination of AO, WP Super Cache & the theme) I'm going to have to do some tests to understand what is causing jQuery to get lost (this might take some time). Could you send me the template zip-file by mail (futtta-at-gmail-dot-com)?

  5. blau
    Member
    Posted 2 years ago #

    I sent you the theme files, thank you for your time.

  6. Frank Goossens
    Member
    Plugin Author

    Posted 2 years ago #

    hmm, nothing in my mailbox i'm afraid. can you retry (and check the mail-address, futtta with three t's, no r ;-) )?

  7. blau
    Member
    Posted 2 years ago #

    Did you get the theme files a week ago?

  8. Frank Goossens
    Member
    Plugin Author

    Posted 2 years ago #

    I did Blau and it is on my todo-list, but I'm focused on shipping a new version of my other plugin (WP YouTube Lyte) now. Hope to push out that new version one of the next couple of days, will turn my attention to Autoptimize (have some small new features in mind) after that. Working on those features and testing (and hopefully identifying the problem) with your theme should be part of that. :-)

  9. blau
    Member
    Posted 2 years ago #

    Thank you futta. I checked out WP YouTube Lyte and it is interesting, I'llleave my feedback about in yous blog's comments.

  10. Frank Goossens
    Member
    Plugin Author

    Posted 2 years ago #

    Just a quick follow-up; the latest version of Autoptimize allows one to specify script that should not be autoptimized. If you would add the relevant string to that list (e.g. jquery if the problem is/ was there), the auto-video resizing feature should work.

  11. conservativeread
    Member
    Posted 2 years ago #

    I also have had issues using both wp super cache and autoptimize I will try this and report back . 1 other thing is I am on cloudflares network and have there minify enabled which is a weak minify. I disable cloudflares and still have minify issues using both wp super cache and autoptimize together my website is http://conservativeread.com running on swift premium theme

  12. mbrsolution
    Member
    Posted 2 years ago #

    Hello @conservativeread this ticket is resolved. You should start a new thread so that the developer can best assist you.

    Kind regards

  13. blau
    Member
    Posted 2 years ago #

    Hello futtta, sorry for the late reply. I updated to the latest and will check the selective js disabling. It is a nice idea, thank you!

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Autoptimize
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic