Welcome Guest, Not a member yet? Register   Sign In
Cache control for CSS and graphics
#1

[eluser]frist44[/eluser]
Just wanted to get a feel for how some of you are using headers to control browser download of static items like CSS resources and images. I know there's some control over this through the output library, but was hoping to get some real life experience and if it was successful in reducing server load for high traffic sites.
#2

[eluser]frist44[/eluser]
anyone use Expire dates and max-age in the headers???
#3

[eluser]grumm3t[/eluser]
Break it out onto say static.domain.com and handle caching through the web server. It's a resource waste to pass everything through PHP.
#4

[eluser]John_Betong[/eluser]
[quote author="grumm3t" date="1285280933"]Break it out onto say static.domain.com and handle caching through the web server. It's a resource waste to pass everything through PHP.[/quote]

I have just moved all my thumbnails to a static subdomain and surprised at how much faster the pages load.

The static images have nearly all been combined into a sprites file and using CSS to display the individual sprites. This is far more efficient than loading separate images.

My next task is to move the Javascript Adsense and button JavaScript files to see if it makes a difference.
#5

[eluser]InsiteFX[/eluser]
The best way is to combine all files into one so that
you are only loading the one file, once loaded it will
then be cached all the time until cache timeout.

Also compress them.

InsiteFX
#6

[eluser]John_Betong[/eluser]
[quote author="InsiteFX" date="1285344658"]The best way is to combine all files into one so that
you are only loading the one file, once loaded it will
then be cached all the time until cache timeout.

Also compress them.

InsiteFX[/quote]

Have you any suggestions for third-party button Javascripts such as Twitter, Digg, StumbleUpon, Reddit, etc?

The remote source code appears dynamic and sends the page-views or Stumbles, etc. to the individual buttons.
 
 
 
#7

[eluser]grumm3t[/eluser]
[quote author="John_Betong" date="1285349989"]
Have you any suggestions for third-party button Javascripts such as Twitter, Digg, StumbleUpon, Reddit, etc?

The remote source code appears dynamic and sends the page-views or Stumbles, etc. to the individual buttons.
[/quote]

A lot of the social sites have "open" APIs that you can use to code your own solution, but you have to consider the effort of doing so versus the performance reward you receive. Your custom solution will require updates over time as the external APIs change.
#8

[eluser]John_Betong[/eluser]
@grumm3t

Many thanks for your clear and concise explanation.

I will review my site and consider if the returns are worth the additional effort.
 
 
 




Theme © iAndrew 2016 - Forum software by © MyBB