Jump to content

Back one step...


funkyjunky

Recommended Posts

Hey guys!Ok here is an easy one for you!Say i have an image (call it bckhome.jpg) When somebody clicks this image i want them to go back to the page they visted previously.Is this possible??Ed :)

Link to comment
Share on other sites

<a href="java script:history.go(-1)">GO BACK</a>

Yep :) But if you're user is coming for Google or so, he will be returned to Google. But you can check on that with a if-statement if you want to :)

Link to comment
Share on other sites

He wanted to click the image not a link.Just do this

<html><body><script type="text/javascript">function goback(){document.location="http://www.runescape.com";}</script><img src="img.jpg"onclick="goback()"></body></html>

But then the history.go(-1)like escee said

Link to comment
Share on other sites

ok but here's code

<html><body><script type="text/javascript">function goback(){history.go(-1)}</script><img src="img.jpg"onclick="goback()"></body></html>

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...