leehughes — 2010-01-07T16:04:17-05:00 — #1
Am struggling with speed on my site getting a overall grade of F from Yslow..
igv — 2010-01-07T16:14:53-05:00 — #2
Putting js in the bottom is not really the thing that I would start with.
It's better to do first things that affect users of your site, such as combining js files, you currently have 27 different js files (plus css), and minifying them if possible. This will make your site load much quicker. If you can enable gzip conmpression on your server.
After that you need to setup expire headers for js/css, since I don't think you modify them often.
This will bump your load speed and your YSlow grade.
leehughes — 2010-01-07T16:16:58-05:00 — #3
There is a minimise tool on firebug yes?
Yes I have heard of GZIP and I have to do that via my server?
igv — 2010-01-07T16:21:43-05:00 — #4
For minifying you can use jsmin. Gzip should be enable on your server for specific request (like js/css files), if you have apache mod_deflate is the module for this.
Expire headers you can write in apache (if you have linux host).
Just to be clear you will need eventually to put as much js as possible into footer, since it will make additional improvements.
leehughes — 2010-01-07T16:23:20-05:00 — #5
I have a vague idea about what you're on about.. I shall do my best :0
leehughes — 2010-01-07T16:24:40-05:00 — #6
Ahh crap. that jsmin is a windows based program.. am on mac
igv — 2010-01-07T16:25:54-05:00 — #7
I don't know if you read it already, but you can click on category titles in YSlow and it will go to pages with description of each problem and some way to solve it.
igv — 2010-01-07T16:27:09-05:00 — #8
I think you can get C source here and compile it on mac? not sure though
igv — 2010-01-07T16:28:06-05:00 — #9
on the same link there is java, php and other versions, I think you can use one of those on mac
leehughes — 2010-01-07T16:28:20-05:00 — #10
yeah, that's beyond me lol
igv — 2010-01-07T16:30:43-05:00 — #11
leehughes — 2010-01-07T16:31:35-05:00 — #12
Ahh that's better
raffles — 2010-01-07T16:38:40-05:00 — #13
If you visit http://rakaz.nl, you will find a method (using PHP) to automatically put all your JS files into a single one, so that you only make one HTTP request. This is one of the main bottlenecks (HTTP requests). The same can be done with CSS.
leehughes — 2010-01-07T16:41:19-05:00 — #14
Ok so I found it and it what http://rakaz.nl/projects/combine/combine.phps
What do I do with that??
Sorry, am not up with this sort of stuff, as you might have guessed
raffles — 2010-01-07T17:07:57-05:00 — #15
You don't even need to look at that PHP source. Just follow the instructions, which basically involve three things:
- Make an .htaccess file and put it in your base directory, with the mod_rewrite code from the instructions in it
- Build your JS/CSS URI as explained in the instructions
- Put the PHP file in the root and then run it.
leehughes — 2010-01-07T17:09:12-05:00 — #16
Right, ok thanks
Will give it a go in the morning when my eyes don't sting
raffles — 2010-01-07T17:28:54-05:00 — #17
I'm all too familiar with that stinging sensation!
dave_morton — 2010-01-07T19:44:49-05:00 — #18
Aren't we all? :lol: [/ot]
leehughes — 2010-01-07T19:47:51-05:00 — #19
Update... av found a neat little plugin called WP Minify that takes my yslow grade from F to C..
only problem is that it messes my css up http://i45.photobucket.com/albums/f56/phi21/Screenshot2010-01-07at233614.png
But still, pretty good eh.. still working on getting it to A
jboesch — 2010-01-07T20:54:56-05:00 — #20
Just thought I'd throw it out there that I wrote an article on minifying your js on the server side: