If I have large javascript files that need downloading, I don't want them to be re-downloaded every time a user clicks on another page within my site that uses the same file. Is there a way to get them to download the javascript once?
Web Development - Is it possible to get users to download javascript files only once per visit?
I believe your JavaScript files get cached by the browser.
Reply:you have to write a cookie that checks if your java-script file still exists (because the user may delete it) in "Temporary Internet Files" folder, if yes then it won't download it.
Positive side:
Your website will fast be opened
Negative sides:
If you update your javascript-file, you'll have to write a new cookie to replace the old file and the old cookie with the new ones.
song meanings
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment