Optimize the order of styles and scripts?

Permalink
Hello,

got a small problem!

Page speed is showing error with a style sheet coming after the base Javascript.

"The following external CSS files were included after an external JavaScript file inhttp://55webdesign.net/. To ensure CSS files are downloaded in parallel, always include external CSS before external JavaScript.
http://55webdesign.net/concrete/blocks/slideshow/view.css?v=96350d9...

This my own theme and I'm not using the slideshow?

I have this problem on more than one website?

Its a clean install on a new server.

Cant find who is calling the style sheet?

Using 5.4.1.1


Any pointers gratefully received.

Steevb
 
Steevb replied on at Permalink Reply
Steevb
This is becoming more irritating!

The issue is with a lot more Concrete5 sites than I first thought, I also thought this issue had been resolved a few months ago but I cannot find the post?

Error= "Ensure CSS files are downloaded in parallel, always include external CSS before external JavaScript."

Depending on the C5 version and depending on what you have or have not added, depends on what error you receive.

Can anyone shed any light on this?


Look forward to a resolution.....
jordanlev replied on at Permalink Reply
jordanlev
Clearing your site cache (Dashboard -> Sitewide Settings) might fix the problem of the slideshow stylesheet appearing without the block being on the page.

As for changing the order that css and js files are included, there's no way to do that in the current system. It just kind of comes out in the order it's set in code (which effectively makes it random as far as end-user is concerned).
Mnkras replied on at Permalink Reply
Mnkras
i was working on the minifier, it works for the front end, but im having trouble with the pesky i18n_js.php file causing it all to crash and burn,
jordanlev replied on at Permalink Reply
jordanlev
Are you working on an addon, or a modification to the core system (or just something in one of your own sites)?

If you want another set of eyes to look at it, I'd be happy to help -- just send me what you have (or point to the files in svn). Do you know what it is about the il8n_js.php files that's making it crash and burn?

-Jordan
Steevb replied on at Permalink Reply
Steevb
Thanks Jordanlev,

Clearing cache does not work.

I had this problem months ago and cant remember how we fixed it, although it was a different inline script.

If you look in header_required.php you can see how the elements are put in head of the page, but I don't which is calling the "<link rel="stylesheet" type="text/css" href="/concrete/blocks/slideshow/view.css?v=9635....."

I don't understand PHP?

Not working on an addon or trying any mods. Just a clean install with sample content. Then activated my own theme, as per normal.

When I check to get everything as mean and clean as is possible with a CMS, I get Page Speed giving me this error?

"Inline script block #1"




@Mnkras

Sorry know nothing about "the pesky i18n_js.php"

YET??
adamjohnson replied on at Permalink Reply
adamjohnson
All of that stuff is in the header_required.php file in /concrete/elements; although, reordering the CSS and js outputted by the cms requires some php knowledge.

Best bet is to google how to load jQuery from the CDN and put all of your themes js and CSS into single files. I have even deleted styles from add ons before and put them in my stylesheet. Obviously, hosting matters too. C5, Hostpapa, and A2 are reported to have good performance.

And as far as concatenating/minifying via C5, I would love to see that happen. Would really give C5 a boost. I'll be interested to see what y'all come up with.
Steevb replied on at Permalink Best Answer Reply
Steevb
Problem partly solved.
Installing Concrete5 WITHOUT the sample content, I lose all reference to the slideshow.css. Good!

But not quite so good, I and most other people have this error with Page Speed.

The following inline script blocks were found inhttp://*********.net/ between an external CSS file and another resource. To allow parallel downloading, move the inline script before the external CSS file, or after the next resource.

* Inline script block #1

Not sure what that is?

But for now I have 95 and 93 on the Google/YSlow richter scale.

That'll have to do...