Forum Moderators: open

Message Too Old, No Replies

Back and forward buttons for an iframe?

         

tekomp

10:29 pm on Nov 6, 2006 (gmt 0)

10+ Year Member



I need to be able to link a back button and a forward button to an iframe, but can't find anything on this. My client has something loaded in the iframe, but if they go to a page in the iframe and they need to get back, there's currently no way for them to do this.

To clarify, this won't be the browsers standard back/forward buttons. I would place them in the page just above the iframe.

Is this easily done? Perhaps some javascript?

Thanks!

kaled

11:48 pm on Nov 6, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Try this...

<input type="button" value="Back" onclick="iframe_name.history.back()">
<input type="button" value="Forward" onclick="iframe_name.history.forward()">

Kaled.

tekomp

11:59 pm on Nov 6, 2006 (gmt 0)

10+ Year Member



That was easy enough. Thank you kaled!