/    Sign up×
Community /Pin to ProfileBookmark

Javascript detect cache file

Hi everyone,

Is any way with javaScript that can tell me some files from my server were saved in the browser (cache). Of course, it has to follow the Same Original Policy. I only want to check whether a file, says, a.txt is successfully saved in cache. I have to use this technique to for image preloading in different page. Very happy if you can help!

Thank,

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@WebnerdApr 05.2009 — Cookies are the only real access you have to the user's filesystem. You can set a cookie at the bottom of your script and then test to see when or if that cookie exists.
×

Success!

Help @catchicken spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.18,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...