Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Getting rid of cached CSS?

Status
Not open for further replies.

jsteph

Technical User
Oct 24, 2002
2,562
US
When I make a change to a stylesheet, and then test it in my browser, it doesn't show up right away. I try to go into Internet Options, and do 'Delete Files' (including offline files), Clear History, even Delete cookies. I then close the browser, reopen, and the change still hasn't gone through. It's not a syntax error in the css, it's a simple, easy change, and sometimes (I don't know what triggers it) the change will finally take place.

So how do I force the changes to happen immediately?
Thanks,
--Jim
 
Is it possible that you have other stylesheets on your server and that it is loading an older version (or another version)? I remember seeing somewhere that it may autoload the sheets if the names are remotely similar...

I believe the solution was to back off a copy of the stylesheet onto your local machine, wipe everything off of the server, then reload the one from your local machine back to the server. But not completely certain...

------------------------------------------------------------------------------------------------------------------------
"Men occasionally stumble over the truth, but most of them pick themselves up and hurry off as if nothing ever happened."
- Winston Churchill
 
Depending on what browser your using, Ctrl+F5 (Forced Reload) will occasionally clear this up.

I have seen some situations with IE where absolutely nothing would force it to stop caching, but that was many years ago so I can't remember exactly what the solution was. I seem to recall finding out there was a proxy server involved that was caching a little too heavily.

One option would be to change the link href to include a querystring value that was randomly generated. This is a little ugly, but should work while your still testing. Once you done I would definatly suggest changing it back to just the std path.

 
Thanks all, I found what it was...the table was being generated in a separate javascript module, and that module referenced another sheet...confusing things was that I was editing that sheet at the same time, not knowing it was also referenced. Sorry for the confusion,
--Jim
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top