WP-Rocket optimization

Posted in: Newspaper
Post count: 12

Hi guys
I tried hard to get good results with WP super cache, but on mobile this solution doesn’t seem to work fine.
So I’m triyng with WP-Rocket which boosts my performance by 15 point on google page speed.
Further optimization could be done with the “remove unused css” feature, but there is a problem with loading some images.
This seem due to a feature in Style.css sheet. Can you help me ?
I paste the solution from wp-rocket support.

thank you in advance
Max

sample page: https://www.massimobasso.com/partire-per-gli-stati-uniti-le-cose-importanti-da-sapere/

—-

I reproduced the problem on my testing environment and found the root cause of the issue.

The issue was caused by Remove Unused CSS feature in WP Rocket, but it is coming from an underlying issue in one of the stylesheets.

This stylesheet: https://www.massimobasso.com/wp-content/themes/Newspaper/style.css?ver=11.4.2 contains an error.
It has a non-valid value width: auto\9;.

Please see the validation error report: https://jigsaw.w3.org/css-validator/validator?uri=https%3A%2F%2Fwww.massimobasso.com%2Fwp-content%2Fthemes%2FNewspaper%2Fstyle.css%3Fver%3D11.4.2&profile=css3svg&usermedium=all&warning=1&vextwarning=&lang=en

The \9 is a hack to make the rule only readable by IE8 up to IE11.

This error is negated on the non-cached page. The browser simply removes this non-existing value.
See the screenshot: https://i.imgur.com/NpugXvX.png

When Remove Unused CSS is enabled and the stylesheet is processed, the value is parsed as width: auto; and added to the Used CSS this way. This value is valid and therefore it is preserved by the browser. But the presence of this value breaks the layout.
See the screenshot: https://i.imgur.com/kcnZ97U.png

The solution would be to resolve the underlying error in the https://www.massimobasso.com/wp-content/themes/Newspaper/style.css?ver=11.4.2
stylesheet.

Removing width: auto\9;
line from the CSS stylesheet will resolve the problem for you.

The issue will be back when you update Newspaper theme. You would need to remove the line again.

Post count: 35449

Hi,
I think that this solution can be solved if you overwrite the css in the child theme css file. In this way you’ll no longer need to remove the width: auto\9; after each theme update.
I will also make a notice to our developers to check and see if they can replace the css code with a better one, but I can not promise that this will be done for the coming update.
Thank you!

Post count: 18

I’m facing the same issue.
It shows – “Stylesheet is missing.”

I tried removing the width: auto\9; but it is not working.

Post count: 35449

Hi rbmagazine,
I think that you are referring to this https://paste.pics/GGN38 if fi so, then the problem can be related to the theme install, maybe it was not installed the right file, also, it can be if you had a child theme or more theme versions (when the theme was updated the old theme was not removed).
If you want, we can take a look at it, for this you can contact us via email at contact@tagdiv.com, we’ll need wp-admin access and you need to have a full backup for your website.
Thank you!

Post count: 181

Guys; contact WP Rocket Team.They help with this, of course if you are using licenced version

Viewing 5 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic.