473,405 Members | 2,354 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Javascript image changer

When using javascript [1] to display a different image (based on the
time of day) both IE and Moz re-execute the js when using the back
function to return to a page with the js on it, this results in users
having to load several images. Opera doesn't do this.

Is there a right or wrong regarding this UA behaviour?

Any way to avoid this?

[1] http://www.pan-europe.utvinternet.ie...ndom_image2.js

--
Spartanicus
Jul 23 '05 #1
1 3172
Spartanicus <me@privacy.net> writes:
When using javascript [1] to display a different image (based on the
time of day) both IE and Moz re-execute the js when using the back
function to return to a page with the js on it, this results in users
having to load several images. Opera doesn't do this.

Is there a right or wrong regarding this UA behaviour?
No. There are no standards that say how browsers must behave when you
leave a page, or when you come back to it.

Opera keeps the page's state as long as it fits in memory, and allows
you to continue where you left it (I believe they clear password
fields for security, though). Other browsers reload the page from the
cache. Both are perfecly reasonable behaviors.
Any way to avoid this?


Use Opera :)

/L
--
Lasse Reichstein Nielsen - lr*@hotpop.com
DHTML Death Colors: <URL:http://www.infimum.dk/HTML/rasterTriangleDOM.html>
'Faith without judgement merely degrades the spirit divine.'
Jul 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

53
by: Cardman | last post by:
Greetings, I am trying to solve a problem that has been inflicting my self created Order Forms for a long time, where the problem is that as I cannot reproduce this error myself, then it is...
2
by: Cynthia | last post by:
I'm looking for javascript code that when I mouse over a menu item will display a picture elsewhere on the page. I know it exists, but the ones I've found so far just swap out the menu item in...
8
by: chrisdude911 | last post by:
how do i add video into a javascript web page with my own custom buttons?
7
by: Spartanicus | last post by:
Afaik the use of a <noscriptelement is frowned upon nowadays. For a JS random image changer I tried to use a replacement by having the script change the HTML src attribute value of an img element....
8
by: Barely Audible | last post by:
Anyone recommend a good javascript image changer - preferably one that does a random image with the ability to post a certain image on a day? TTFN Jim
4
by: init0 | last post by:
I am VERY new at javascript and I cannot seem to figure out why I keep getting the following error message when I try to run this code: Error "document.myform is null or not an object" I just...
3
by: GloStix | last post by:
What I have now is a static banner that loads as an background-image via css stylesheet but I put on top of that a flash banner so it would load the static banner and the flash will fade in. The...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.