beginner: href link like "back"

M

Ma³y Piotruœ

Hello,
(I am sorry for my English, it is not my native language.)
I am new to JavaScript. Could you help me please with the following
problem?:
I need to make a href link on HTML page that leads the user back to
the previus page. I did it (accourding to downloaded course) this way:
<a href="javascript:history.back()">Back</a>
It doesn't work. Could you tell me plase and suggest correct solution?
Thank you very much.
 
R

Randy Webb

Ma³y Piotruœ said the following on 11/12/2005 12:18 PM:
Hello,
(I am sorry for my English, it is not my native language.)
I am new to JavaScript. Could you help me please with the following
problem?:

That problem of yours was already asked/answered in this group in the
last 2 days.
I need to make a href link on HTML page that leads the user back to
the previus page. I did it (accourding to downloaded course) this way:
<a href="javascript:history.back()">Back</a>

You need to find a new course.

But, when you opened that page, was there anything in the history to go
back to? Meaning, if you open that page first, there is nowhere to go
"back" to so no, it won't work. And you can *not* make it work reliably
in a default security environment on the web.
 

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

No members online now.

Forum statistics

Threads
473,773
Messages
2,569,594
Members
45,125
Latest member
VinayKumar Nevatia_
Top