molendijk
12-07-2007, 12:36 PM
Hello everybody,
I'm experimenting with framesets and noticed that:
<a href="bla.html" onclick='top.location.href="#bla.html"'>bla</a>
gives me a new URL in the top location bar (as desired), even if the targeted frame is not _top (but the main frame).
Now, this method adds an extra entry to the history. That is, if I have, for example, '../index.html' in the address bar (and 'index.html' in the main frame) before clicking on the bla link, then, after clicking on the bla-link, I have '..index.html#bla.html', then if I go back (back button) I still have the content of bla.html in the main frame, but the URL in the address bar has already returned to '../index.html'. I have to do an extra 'back in history' to get 'index.html' in the main frame again.
In other words, the method works well, except for the extra entry I want to get rid of (in the history queue). (The replace-method doesn't work here, since it deletes the history). Any ideas on how to solve this?
Thanks,
Arie Molendijk.
I'm experimenting with framesets and noticed that:
<a href="bla.html" onclick='top.location.href="#bla.html"'>bla</a>
gives me a new URL in the top location bar (as desired), even if the targeted frame is not _top (but the main frame).
Now, this method adds an extra entry to the history. That is, if I have, for example, '../index.html' in the address bar (and 'index.html' in the main frame) before clicking on the bla link, then, after clicking on the bla-link, I have '..index.html#bla.html', then if I go back (back button) I still have the content of bla.html in the main frame, but the URL in the address bar has already returned to '../index.html'. I have to do an extra 'back in history' to get 'index.html' in the main frame again.
In other words, the method works well, except for the extra entry I want to get rid of (in the history queue). (The replace-method doesn't work here, since it deletes the history). Any ideas on how to solve this?
Thanks,
Arie Molendijk.