...

View Full Version : automatically cache outbound (external) links?



ac1d
05-31-2007, 09:35 AM
Hi,
How would I go about making my website automatically cache external links and provide an option to "view cached page"?
Also, are there any effective ways to cache without using up a lot of diskspace/bandwidth? Could i do "text only" caches?

aedrin
05-31-2007, 05:21 PM
You would read one of your pages, find all links that are external (using a regex). Then for each links, lead the HTML through cURL, PEAR or external fopen (if host allows it). By only loading the HTML you are getting basically text only. But you'd lose any markup applied through CSS.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum