Flash Vista - Главная страница
Новейший клёвый сайт
The Two Tales
О сайте | Архив
Главное меню
Главная страница
Новые ссылки
Лучшие ссылки
Популярные ссылки
Клёвые сайты
Поиск

Flash Tutorials
Flash Resources
Flash News
Flash Templates
Flash Intro Templates
Website Templates
Flash Games
Flash Books
FlashVista Polls
Карта сайта


Случайная ссылка
English
Hoyte van Hoytema Cinematographer
О сайте | Ещё ссылку !
FlashVista
Вход в систему
Регистрация
Подписка

Добавить ссылку
Изменить ссылку
Любимые ссылки
Предложить категорию

Advertise with us
Support us
Credits / Thanks
Contact

Flash Templates:

More Templates ...

Подписка Рассылок
Пользователь

Пароль



Регистрация
Забыли пароль ?
Partner websites
iPhone cases and accessories
Free Seo Tools
Free Tutorials
Free Video Tutorials
Best Free Scripts
Wii Fit
Wii Fit News
Other Resources
Порекомендовать
Порекомендовать этот сайт другу


Подписка Рассылок
Статус: Не авторизирован

Русский English German French Spanish Italian Portuguese Russian Polish Finnish Dutch Swedish Thai Romanian Traditional Chinese Simplified Chinese
ПоискНе авторизирован
Запрос: Искать: Расширенный поиск


Stop Browser Caching Data


NEW Flash Tutorials in Video Format - Powered by LearnFlash.com: 45 minutes of flash tutorials now available in streaming format or download. Topics Include flash for beginners, text effects, actionscripting, audio/video, flash 8 and more.


Printer version



by Guy Watson
www.flashguru.co.uk

Are you sick of your browser caching loaded variables? are you sick of loaded movies being cached? Then heres how to stop the browser from caching your data...

The browsers cache comes in handy for slow connections, all the requests you make to a webserver are stored in a local folder on your computer, so that the next time you make the same request, the file can be loaded from the local hardrive as opposed to having to download the data over the internet again. However this can cause problems when you are building web based applications, you need to be sure, as the developer, that the latest content is being viewed. To achieve this in your Macromedia Flash Movies is relativley straight forward, all you need to know is the way the browser cache works. The browser cache, stores the 'full' url, along with the data associated with that url as a local file when a request is made to a webserver and the data is completley downloaded. If that same request is made again, to the webserver, then your browser uses the local version stored previously, unless you have changed the default browser settings. So for example, if i was to do a load variables call to a specific url, the data for that load variables call is cached when it has been fully downloaded, the next time i do the same load variables call, the browser returns the data it stored previously. To stop this from occurring, all you need to do, is make sure that the url you are making a request to, is unqiue, each and everytime. To make the url unique each and everytime without moving the data around, or changing any filenames, you simply have to 'append' a unique value to the url of the request as a name/value pair. So for example, to stop the following load variables call from caching in the users browser:


this.loadVariables("http://www.flashguru.co.uk/myscript.php");

We simply append a 'unique' value to the url:


unique=new Date().getTime() //will always be unique
this.loadVariables("http://www.flashguru.co.uk/myscript.php?unique="+unique);


The above request will be stored in the users cache but the same request will 'never' be made again, therefore the data the browser has stored in the cache will never be displayed/retrieved. The same process is used to stop loaded movies caching.

(Добавлено: 02-06-2004, Посещения: 0, Рейтинг: 2.94, Голоса: 17, Комментарии: 3)
Добавить в Любимые ссылки Порекомендовать другу

Комментарии: (3)

Help... Iv got a large site with the same flash footer on hundreds of html pages...

Anyway of stopping browsers caching from with in the flash file... ie not modifying the individual html pages the flash enbeds into???

(Добавлено: 08-03-2006 Пользователь: Гость)

that doesn't work anymore.
Since this morning (after updating my IE with the last security update) i'm having trouble with cache trying to load dynamic content on my flash movies.

(Добавлено: 11-18-2004 Пользователь: Гость)

the only problem with this is that then your users cache becomes filled with garbage if your site has repeat visitors which any administator wants. But as an offsite administrator having to deal with large cache directories is a pain. computers become slow due to the amount of uncleaned browser caches.

the theory is sound, but application might deter return users.

(Добавлено: 10-29-2004 Пользователь: Гость)


Добавить комментарий
Please note:
We review EVERY comment before it appears on the site, so please dont waste your time by posting spam links :)
No URLs allowed, no HTML please.

If you register or login first, your review will contain your nickname


Проголосовать



Великолепно!
Очень хорошо
Хорошо
Посредственно
Неудовлетворительно