View Full Version : history.go(+1) doesn't do it's thing here

02-03-2007, 06:02 AM
I have another problem that is probably solveable but not with history.go(+1), which is what I would expect.

I want to be able to go from page 1 to page 2 in two ways.

You can do it by clicking on the numbers and the back button does its job as you would expect.

But using the "go" button (enter the lesson number) seems to bypass the back button's history.

The (cutdown) page demonstrating the problem is here:


The way the go button works is fine and goes to page 2 nicely from page 1, but no history update.

It must have something to do with this function in the routine:

function gopage() {
var ex = document.getElementById('exField').value;
return false;

I tried placing 'history.go(+1)' into that function but it didn't change anything. I don't understand why. (Because of the 'replace'?)

02-03-2007, 09:23 AM
Try top.location = getPath(ex); instead.

02-03-2007, 09:59 AM
As you can see, that certainly fixed it.

Many thanks indeed!