Minifying causes slider and images to break

When using Hummingbird to Minify this error is caused "PHP Warning: parse_url() expects parameter 1 to be string, array given in /nas/content/live/svresort/wp-content/plugins/wp-hummingbird/core/modules/class-module-minify.php on line 760, referer: https://southernreso…type=listing&lodging=Condo

This error is repeated in the error logs." Which removes the slider and images. How do I fix this?

  • Adam Czajczyk

    Hello Business Solutions,

    I hope you're well today and thank you for your question!

    I took a look at your site (Firefox and Edge) and I assume that the minification is currently disabled is that right?

    The message that you are getting in logs is just a warning so it's more like an information to the developers that there may (but not necessarily must) be some issue that may be affecting site performance. Usually however it's not "dangerous".

    The issue here is in my opinion that some of the files should not be either minified or combined or both. That may also be a reason for the warning that you are getting.

    The minification process is quite complex and while on many sites it works "out of the box" there's no way to determine correct settings for all possible setups in a fully automated way. Therefore, on some sites it takes a bit to "fine tune" that. The process basically involves:

    - turning minification on with "default" settings
    - examining the page to see if anything is broken and if so, what that is
    - then switching off "minify" toggle and/or "combine" toggle for related files.

    Finding about related files and finding proper combination of minify/combine options on/off may be a bit daunting task and it involves a dose of... intuition. For example, if you see that only the slider is broken, the first thing to check would be to use drop-down list on "Hummingbird -> Minification" page to select slider plugin and then switching off "minify" for its CSS files, then - if necessary - for its JS files and - if that still doesn't help - repeating the same for "combine" column.

    Sometimes it turns out that also some of the theme files has to be treated that way. Give it a try please and let me know if you managed to handle that. If not, please grant me a support access to your site so I could check that myself. Here's the guide on granting support access:

    https://premium.wpmudev.org/manuals/wpmu-dev-dashboard-enabling-staff-login/

    Best regards,
    Adam

  • Predrag Dubajic

    Hi Business Solutions,

    I had a look at your staging site and after removing some theme files from minification and daterange picker as well and it should be working fine now.

    Minification can be tricky tool to work with as it depends on the theme and plugins you have on your site, how they handle minification and how they work together.
    Because of this Minification settings are pretty much different on each installation.

    Best regards,
    Predrag