Speed up your site.. lose {stylesheet}
Re: Speed up your site.. lose {stylesheet}
Hmm. What's your experience with css gzipping and older browsers?
Re: Speed up your site.. lose {stylesheet}
another tip (that i use here)...
if you have multiple sites that use the same stylesheet(s), you can refer the 'other' sites to the first one's stylesheets, either by putting the full url in the stylesheet link(s):
instead of just
OR, call them through cmsms (lookup the full url in the html output source of the first site):
instead of {stylesheet}
you just need to remember which site's stylesheets are used so you know which one to edit later on. i have three cmsms sites that use the same stylesheets; used to use the second solution, but changed to external files and use the first one now for them.
note: the second solution doesn't do anything (to improve site performance) under windows/iis, as cmsms on that platform always (generates and) sends the stylesheets on each page view (doesn't send a 304:not modified if the generated stylesheet matches client browser cache like it does on apache)... use external files instead (they're faster anyway, on any platform).
also, if you don't want references to ./stylesheet.php clogging up & skewing stats like webalizer (it will be the most-accessed 'page' of a cmsms site), external stylesheets are a must.
and remember, if you use yahoo yui css or scripts, you can link to them directly off yahoo's servers... which will cache, and (some) may even already be present in your visitor's browser cache from other sites they've been to.
if you have multiple sites that use the same stylesheet(s), you can refer the 'other' sites to the first one's stylesheets, either by putting the full url in the stylesheet link(s):
instead of just
OR, call them through cmsms (lookup the full url in the html output source of the first site):
instead of {stylesheet}
you just need to remember which site's stylesheets are used so you know which one to edit later on. i have three cmsms sites that use the same stylesheets; used to use the second solution, but changed to external files and use the first one now for them.
note: the second solution doesn't do anything (to improve site performance) under windows/iis, as cmsms on that platform always (generates and) sends the stylesheets on each page view (doesn't send a 304:not modified if the generated stylesheet matches client browser cache like it does on apache)... use external files instead (they're faster anyway, on any platform).
also, if you don't want references to ./stylesheet.php clogging up & skewing stats like webalizer (it will be the most-accessed 'page' of a cmsms site), external stylesheets are a must.
and remember, if you use yahoo yui css or scripts, you can link to them directly off yahoo's servers... which will cache, and (some) may even already be present in your visitor's browser cache from other sites they've been to.
eternity (n); 1. infinite time, 2. a seemingly long or endless time, 3. the length of time it takes a frozen pizza to cook when you're starving.
4,930,000,000 (n); 1. a very large number, 2. the approximate world population in 1986 when Microsoft Corp issued its IPO. 3. Microsoft's net profit (USD) for the quarter (3 months) ending 31 March 2007.
CMSMS migration and setup services | Hosting with CMSMS installed and ready to go | PM me for Info
4,930,000,000 (n); 1. a very large number, 2. the approximate world population in 1986 when Microsoft Corp issued its IPO. 3. Microsoft's net profit (USD) for the quarter (3 months) ending 31 March 2007.
CMSMS migration and setup services | Hosting with CMSMS installed and ready to go | PM me for Info
Re: Speed up your site.. lose {stylesheet}
They will only be gzipped if the browser supports it.Vin wrote: Hmm. What's your experience with css gzipping and older browsers?
But I can't imagine, that it is really faster. If you have small css files, their submission makes out a very small part of the page load time.
If you zip them transmitting will not be much faster but an instance of PHP starts for each of the files.
Henrik
Re: Speed up your site.. lose {stylesheet}
gzipped stylesheets wont be "faster" for most sites.. unless they're insanely huge...henrik wrote:They will only be gzipped if the browser supports it.Vin wrote: Hmm. What's your experience with css gzipping and older browsers?
But I can't imagine, that it is really faster. If you have small css files, their submission makes out a very small part of the page load time.
If you zip them transmitting will not be much faster but an instance of PHP starts for each of the files.
Documents (1 file) 7 kb (31 kb uncompressed)
Objects (0 files)
Scripts (5 files) 6 kb (36 kb uncompressed)
Style Sheets (15 files) 23 kb (125 kb uncompressed)
i shoot for < 10k for stylesheets (most end up around 5-6k or less).... if you have large stylesheets with lots of comments, try running them through http://www.cleancss.com/index.php -- using the 'optimized' stylesheets on the site and keeping the formatted and commented ones on the local pc for later editing.
eternity (n); 1. infinite time, 2. a seemingly long or endless time, 3. the length of time it takes a frozen pizza to cook when you're starving.
4,930,000,000 (n); 1. a very large number, 2. the approximate world population in 1986 when Microsoft Corp issued its IPO. 3. Microsoft's net profit (USD) for the quarter (3 months) ending 31 March 2007.
CMSMS migration and setup services | Hosting with CMSMS installed and ready to go | PM me for Info
4,930,000,000 (n); 1. a very large number, 2. the approximate world population in 1986 when Microsoft Corp issued its IPO. 3. Microsoft's net profit (USD) for the quarter (3 months) ending 31 March 2007.
CMSMS migration and setup services | Hosting with CMSMS installed and ready to go | PM me for Info
Re: Speed up your site.. lose {stylesheet}
Thanks for the link. I tried optimizing stylesheet on my own (and with the help of my text editor for the inline compression); although the compression of cleancss was just 4.8% then, it's certainly better.kermit wrote: i shoot for < 10k for stylesheets (most end up around 5-6k or less).... if you have large stylesheets with lots of comments, try running them through http://www.cleancss.com/index.php -- using the 'optimized' stylesheets on the site and keeping the formatted and commented ones on the local pc for later editing.
15 files? What are they for? Alternative stylesheets, print stylesheets? Aren't there too many?kermit wrote: Style Sheets (15 files) 23 kb (125 kb uncompressed)
Re: Speed up your site.. lose {stylesheet}
I don't have a lot of experience with it... But, I'm pretty sure the browser just asks if there is a compressed version and grabs it if it is available.Vin wrote: Hmm. What's your experience with css gzipping and older browsers?
I think overall the less sql requests made and the less files requested from a html page is way the way to go regardless how much a css (or any file served) can be compressed.
"The art of life lies in a constant readjustment to our surroundings." -Okakura Kakuzo
--
LinkedIn profile
--
I only speak/write in English so I may not translate well on International posts.
--
--
LinkedIn profile
--
I only speak/write in English so I may not translate well on International posts.
--
Re: Speed up your site.. lose {stylesheet}
AdoDB (not lite) has an option too to compress communication between frontend and database server ...mww wrote: I think overall the less sql requests made and the less files requested from a html page is way the way to go regardless how much a css (or any file served) can be compressed.
Re: Speed up your site.. lose {stylesheet}
Hello everybody,
If the lowest maximum transfer unit (MTU) of the network from the server to the client is 1500 bytes, a 2k uncompressed stylesheet needs 2 packets (and packet ordering management, retransmission if failure etc). This is a network time cost. The same 2k fit in a single 1500 byte packet when compressed to 450 bytes. Whis the same compression ratio, a 6k stylesheet still fits in a single 1500 bytes packet.
Moreover, servers' cache can cache the compressed versions of the almost static stylesheets. So it doesn't take extra CPU on the server side after initial compression. As decompression is less CPU intensive, any browser CPU can do it easily on the client side. Static data compression is almost allways a win for broadcasting.
Pierre M.
Compression may help a transfer fit in network packets boundaries :henrik wrote: They will only be gzipped if the browser supports it.
But I can't imagine, that it is really faster. If you have small css files, their submission makes out a very small part of the page load time.
If you zip them transmitting will not be much faster but an instance of PHP starts for each of the files.
If the lowest maximum transfer unit (MTU) of the network from the server to the client is 1500 bytes, a 2k uncompressed stylesheet needs 2 packets (and packet ordering management, retransmission if failure etc). This is a network time cost. The same 2k fit in a single 1500 byte packet when compressed to 450 bytes. Whis the same compression ratio, a 6k stylesheet still fits in a single 1500 bytes packet.
Moreover, servers' cache can cache the compressed versions of the almost static stylesheets. So it doesn't take extra CPU on the server side after initial compression. As decompression is less CPU intensive, any browser CPU can do it easily on the client side. Static data compression is almost allways a win for broadcasting.
Pierre M.
Re: Speed up your site.. lose {stylesheet}
Agreed. enable apache's mod_deflate to compress everthing to the client. For heavy sites or pages, this can significantly increase laod times. It helps anyone on a dialup for sure, regardless of page size. It does eat extra CPU cycles on the server.Pierre M. wrote: Hello everybody,Compression may help a transfer fit in network packets boundaries :henrik wrote: They will only be gzipped if the browser supports it.
But I can't imagine, that it is really faster. If you have small css files, their submission makes out a very small part of the page load time.
If you zip them transmitting will not be much faster but an instance of PHP starts for each of the files.
If the lowest maximum transfer unit (MTU) of the network from the server to the client is 1500 bytes, a 2k uncompressed stylesheet needs 2 packets (and packet ordering management, retransmission if failure etc). This is a network time cost. The same 2k fit in a single 1500 byte packet when compressed to 450 bytes. Whis the same compression ratio, a 6k stylesheet still fits in a single 1500 bytes packet.
Moreover, servers' cache can cache the compressed versions of the almost static stylesheets. So it doesn't take extra CPU on the server side after initial compression. As decompression is less CPU intensive, any browser CPU can do it easily on the client side. Static data compression is almost allways a win for broadcasting.
Pierre M.
Re: Speed up your site.. lose {stylesheet}
I just made a "real" plugin out of it 
http://dev.cmsmadesimple.org/projects/static-css/
Regards,
Henrik

http://dev.cmsmadesimple.org/projects/static-css/
Regards,
Henrik
Re: Speed up your site.. lose {stylesheet}
Henrik,
Tried this plugin, and I nearly got it working; the pictures in the header (placed there by the stylesheet), don't show up. the rest of the page is shown. I removed the plugin, in case you wanted to look. My site iswww.uisge-beatha.eu
Regards,
Gregor
Tried this plugin, and I nearly got it working; the pictures in the header (placed there by the stylesheet), don't show up. the rest of the page is shown. I removed the plugin, in case you wanted to look. My site iswww.uisge-beatha.eu
Regards,
Gregor
Re: Speed up your site.. lose {stylesheet}
Walking through the hall, I suddenly thought it might have to do with the directory path. In my stylesheet it is:
I replaced it with (don't know how to change color inside a code or quote, I placed a / before uploads):
Now it's working 
Code: Select all
background: url(uploads/images/logo_links1.gif) no-repeat 0 0px;
Code: Select all
background: url(/uploads/images/logo_links1.gif) no-repeat 0 0px;

Last edited by Gregor on Tue Apr 24, 2007 12:19 pm, edited 1 time in total.
Re: Speed up your site.. lose {stylesheet}
@styson & others : to prevent some CPU cycles being eaten you can enable mod_cache between the client and mod_deflate.
Pierre M.
Pierre M.
Re: Speed up your site.. lose {stylesheet}
At least on my 1.0.5 the 'ccontent' solution stops the internal 'Search' working? It goes no where if you try to search? Anybody else have this?
Russ
Russ
Re: Speed up your site.. lose {stylesheet}
May be the results page should not be cacheable ?
Pierre M.
Pierre M.