0

Okay,

My site report is here that I am developing - https://tools.pingdom.com/#!/bBE0r0/www.waggypetservices.co.uk/

My only issue now is that something is calling style.min.css when this doesn't and has never existed...

I have checked the fucntions.php file and I can't see anything that could be calling this. I have also checked where the report says the file is located in which is it obviously not there.

I am using the mesmerize theme... anyone got any idea on how I can locate the code calling this or stop it being called as it is adding a second on my website speed times due to this not being found and throwing an error.

Any help will be appreciated and please ask if you need me to past any of my website codes in here.

Thanks,

Harvey

0

You can tell by the ID on the <link href="... tag that the stylesheet's ID is mesmerize-style, so you should be able to dequeue with this function in your child theme.

wp_dequeue_style( 'mesmerize-style' );

Make sure it's hooked into wp_enqueue_scripts with a higher priority than the parent theme's hook (probably 10).

That's the general answer that would apply to most WordPress sites, and is a useful answer to the community, but since I've looked at your specific parent theme I can elaborate on your specific issue (which really should have originally been addressed to the author):

Your parent theme is loading its stylesheet in a weird way. It's using get_stylesheet_uri(), which will load style.css from the theme, or from the child theme, if it exists. But it's modifying it to load style.min.css, which you mustn't have in your child theme. You could simply create an empty style.min.css to stop the 404, or you could dequeue the parent theme's enqueue of the missing stylesheet, as above.

  • Okay thanks for explaining that as I couldn’t tell either... it great with PHP so it was confusing me as I couldn’t see what was happening. I will create an empty file and see if everything works fine and let you know – Harvey Dec 2 '17 at 12:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.