UserScripts Archive
Caching links - Printable Version

+- UserScripts Archive (http://usa.x10host.com/mybb)
+-- Forum: UserScripts Archive (http://usa.x10host.com/mybb/forumdisplay.php?fid=1)
+--- Forum: Script Support (http://usa.x10host.com/mybb/forumdisplay.php?fid=3)
+---- Forum: W.A.R. Links Checker Premium (http://usa.x10host.com/mybb/forumdisplay.php?fid=6)
+---- Thread: Caching links (/showthread.php?tid=215)



Caching links - Nenad__ - 03-06-2017

Is it possible to add a feature that caches links that already has been checked and automatically mark those links as dead/alive without checking them again? It would speed up a lot of things.

Thanks for your hard work.


RE: Caching links - mental - 03-06-2017

(03-06-2017, 09:13 AM)Nenad__ Wrote: Is it possible to add a feature that caches links that already has been checked and automatically mark those links as dead/alive without checking them again? It would speed up a lot of things.

Thanks for your hard work.

i don't know a way to do that.


RE: Caching links - Nenad__ - 03-06-2017

Ok, thanks. If you find out how to do it it would be great addition to the script. Smile


RE: Caching links - Nenad__ - 03-07-2017

Here is an idea how it could work.

http://stackoverflow.com/questions/14266730/js-how-to-cache-a-variable

The checked links should be added to a localStorage for 1 minute. Dead links to localStorage['dead'], alive links to localStorage['alive'] etc. and to the values of localStorage should be given a class "alive_link", "adead_link" etc to be recognized and shown on the page as dead or alive.