Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,155,540 members, 7,827,015 topics. Date: Tuesday, 14 May 2024 at 04:24 AM

Quiz Time : How To Bypass Cache - Webmasters - Nairaland

Nairaland Forum / Science/Technology / Webmasters / Quiz Time : How To Bypass Cache (1965 Views)

How To Configure W3 Total Cache Plugin and increase your website speed. / How To Bypass Compulsory Registration On Any Site / Blocked By Mypsace, Facebook, Twitter, Aol? Bypass Proxy Server! (2) (3) (4)

(1) (Reply) (Go Down)

Quiz Time : How To Bypass Cache by Nobody: 10:29pm On May 10, 2011
I was reading an article some few seconds back, it was talking about browser caching,
being a cause of problem for clients not seeing the latest version of your web page.

Now, my question is that, can someone supply us with some techniques for forcing
the browser to always reload the following types of files:
javascript, images, css

This is an open question realy, because there are so many methods to do this. . .
there are both client and server sides methods.

When using ajax too, the same problem occurs atimes. . .
Re: Quiz Time : How To Bypass Cache by Nobody: 10:33pm On May 10, 2011
I think you guys should read this article, http://www.vodahost.com/vodatalk/bluevoda-tips-tricks-shortcuts/15573-browser-caching.html
The method highlited here is not one of the methods i use at all, the one i use too is about is effective as this, but my favorite method
is universal for any media that will be served over the web, it includes even music and videos.

Re: Quiz Time : How To Bypass Cache by yawatide(f): 11:02pm On May 10, 2011
I don't know if "bypass cache" is the right phrase here, IMHO. I would rather say, "how to force the latest version of a file" or "how not to load a cached file". I know, tis a play on words but I think mine is clearer cool

What I am used to seeing is tacking on a version variable to the end of files like CSS and JS. So for example, if I have a file called yawa.css, if I want to guarantee that I always am pulling the latest version from the server, I can do something like so:
www.xyz.com/css/yawa.css?v=1.

The "1" above is a random number generated by backend code (PHP, JSP, etc). When I new version of the file goes out, all we would do is update the version number.

For those who can afford (usually corporations), they use a company called akamai. You send your files to them, they host it for you and handle all the caching issues for you.
Re: Quiz Time : How To Bypass Cache by Nobody: 11:43pm On May 10, 2011
You are free to remodify the phrase as you please, at least i have provided a thread that examplify what i was trying to say sha. . .
oya, answers now, BTW yawa, your message was swallowed by the stooopid bot, but as always, we know how to decode it. . .
Re: Quiz Time : How To Bypass Cache by yawatide(f): 1:10am On May 11, 2011
Let me try again. ye ye spam bot smiley

You tack on a name value pair at the end of the file name, something like version equals 1.1. Then each time you update the file, you update the version number. The version number would typically be assigned via a backend language.

On a corporate scale, companies tend to use the services of akamai, who host your files and handle all the caching issues for you.
Re: Quiz Time : How To Bypass Cache by Nobody: 8:51am On May 11, 2011
Can we see some sample codes por favor, as a programmer, i can only read codes, i cannot read simple ingles fairly easily. . . (because i have dual core processors in place of brain cells)
Re: Quiz Time : How To Bypass Cache by yawatide(f): 12:00pm On May 11, 2011
Re: Quiz Time : How To Bypass Cache by Nobody: 12:51pm On May 11, 2011
yawa-ti-de:

www.abc.com/css/yawatide.css?version=1.4.3
tres bien, there is another code that allows you to use the same name for all your files, it
just clears the cache using php cache code. . .which seem to have skipped my memory at
the moment, it can be used to deliver any content type.
I will do a dns lookup on some sites i have used that technique on, i know it was used in
that my code http://.net/demos/jupload/
the url of the image is constantly http://.net/demos/jupload/demo.php
but immediately any new photo is loaded, it overrites the old one. . .and the changes
reflect almost immediately without changing the url
Re: Quiz Time : How To Bypass Cache by Zahymaka(m): 8:09pm On May 11, 2011
Versioning as yawa-ti-de mentioned.

Ajax posts are not cached, so sending a post request instead of get shouldn't do any caching.

(1) (Reply)

Only For Webmasters On Nairaland / Get A Business Website For FREE Just Pay #19,999 For Domain And Hosting / Get 100% Free Web Hosting With Coupon "nigeria"

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 17
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.