Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

One thing I've noticed where all modern browsers fall short is caching. I remember years ago in Internet Explorer 5 - a browser that was the horrors by todays standards! - that I could select "File/Offline Mode" at any time, and then browse everything I visited in the last couple of days from cache. It would even automatically activate offline mode when the connection went down. Also it seemed to use the cache much more aggressively than nowadays even when browsing online. All of this was a neccessity with the modems of the day and their slow and unreliably connections. Nowadays, when I'm travelling with my netbook I could frequently use such a feature, especially when WiFi is flaky or not available.

Firefox still has an option to "work offline", and it works on a handfull of pages, but it seems very limited. Also there is no straightforward way to see which sites in my history are cached.

Is there a way to make caching more "agressive" or comprehensive, and offline mode useful again? Maybe extensions, or a certain browser?

share|improve this question

closed as not constructive by Indrek, Randolph West, soandos, allquixotic, KronoS Aug 20 '12 at 19:56

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

2  
Did you consider the ridiculously widespread use of AJAX dynamic content-loading? There's often no easy way to determine what a "page" to cache is. –  Daniel Beck Aug 20 '12 at 12:31
    
@DanielBeck: I know, this, and the fact that many websites nowadays have logins makes it a lot harder. But even on pages with AJAX, the browser saves the document state in memory and can reload it when you press "Back" or "Forward". It could just take a snapshot of that. I don't expect dynamic stuff (e.g. GMail) to work. –  jdm Aug 20 '12 at 12:38
1  
I'd really hate if somebody came to PC after I've used my online banking, clicked "go offline" and "back"'ed all the way to card details. It is not browsers, it is sites that instruct browser what they can cache and what they can't. –  Oleg V. Volkov Aug 20 '12 at 13:21
    
@OlegV.Volkov: That's why you have a "Guest" account on PCs. OS security is far better than what your browser attempts to achieve. It's main job is protecting you from the world, not protecting you from you. –  MSalters Aug 20 '12 at 14:16
    
@MSalters at very least you'll have tell me how to create another "guest" account on public, but otherwise restricted and secure box. However, this is not the main issue. There are thousands of reasons author of site might want to instruct browser not to cache data and thousands of ways things can break horribly if you use heavy magic™ to deliberately make browser ignore this. Just don't do it. –  Oleg V. Volkov Aug 20 '12 at 14:24

2 Answers 2

Earlier versions of squid (2.2 and before) have an "offline_mode" feature.

This mode turns off cache validation, that is, if the resource is already in the squid cache, squid will not contact the original website to check whether the cached resource is valid/fresh or not.

Combine offline_mode on and an aggressive catch-all refresh_pattern such as

refresh_pattern . 10080 9999% 43200 override-expire ignore-reload ignore-no-cache ignore-no-store ignore-must-revalidate ignore-private override-lastmod reload-into-ims store-stale

and you can go offline for months and still be able to revisit static websites you visited before!

For more info, read http://www.squid-cache.org/Doc/config/offline_mode/ and http://linuxdevcenter.com/pub/a/linux/2001/08/02/offline_squid.html . Squid runs on most operating systems, so give it a spin.

I hope this answers your last question.

Now to answer the "why" on your question title, the web now is not what it was since IE5. The majority of websites will break in offline mode. The web has become more reliant on dynamic live content, i.e., much content now is not designed to be cached for long. Read this question I asked in the Squid Users mailing list.

share|improve this answer

A HTML author can use header and meta tags to instruct a browser to not cache a page.

This is the trend now, given that HTML and browsers are more or less these days considered to form a general application-level protocol/runtime environment, and not just a static document retrieval protocol.

It's technically possible to strip/change any unwanted stuff from HTML documents using a proxy server. squid would provide the framework for this capability - including running HTML requests through a script that can modify stuff on the fly - but you'd have to write your own script that modifies tags creating behavior you don't want. Also, messing with Javascript in pages is messy, time consuming, different for each site, and the payoff is usually not worth the effort.

I don't know of a turnkey solution that provides this.

Generally I've found it helpful to capture pages by printing them to .PDF or similar instead of relying on the browser cache to remember what I was doing.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.