Problem with 'window.location.replace("file.htm")'

N

Norman Swartz

Script works in Firefox but not in IE.

Here's what I want to do:

file1.htm loads file2.htm
file2.htm loads file3.htm
The "Back" tab in file3.htm returns the user to file1.htm

A number of Web sites offer the following bit of coding to do what I
want. I have used this coding in file2.htm (to load file3.htm).

<script language="javascript1.1">
<!--
function leapfrog()
{
window.location.replace("file3.htm") ;
}
// -->
</script>
:
:
<a href="javascript:leapfrog()"><b>Continue</b></a>

In Firefox, this coding works exactly as I want. But in IE, when one
clicks on the "Back" tab in file3.htm, one is returned to file2.htm
instead of file1.htm. What changes are needed so that the code works as
I want in both IE and Firefox? Thanks.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,982
Messages
2,570,189
Members
46,734
Latest member
manin

Latest Threads

Top