areyouready344
asked on
how to create a html back button?
To create a html back button, do I need javascript and can I create a html back button without using javascript, if so, how can i accomplish this?
My html code don't use javascript...
My html code don't use javascript...
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
....lol posts at same time, "return true" is JS
Check this:
http://www.computerhope.com/issues/ch000317.htm
http://www.computerhope.com/issues/ch000317.htm
history.go is JS too.
Using javascript:
<a href = "javascript:history.back() ">Back</a>
<a href = "javascript:history.back()
"Can I create a html back button?"
No.
No.
or combining all our suggestions - the canonical
<a href="#" onClick="history.back(); return false">Back</a>
Zwei: No need for form tags and no need for return true
<a href="#" onClick="history.back(); return false">Back</a>
Zwei: No need for form tags and no need for return true
ASKER
The command INPUT TYPE="button" VALUE="Back" onClick="history.go(-1);;" > is not working for me. I don't have javascript in the html code...
you don't need javascript in the code to make it work, sure you have the < at the start of the statement?
<INPUT TYPE="button" VALUE="Back" onClick="history.go(-1);;" >
<INPUT TYPE="button" VALUE="Back" onClick="history.go(-1);;"
And history.go IS javascript
ASKER
GwynforWeb, code below shows what I'm doing. As you can see, I'm loading the html code within a bash shell script. Anything you can see I'm doing wrong here?
#!/bin/bash
echo Step 1
source "$start.sh"
cat << BROWSER
@{{
<request>
<name> Test 1 </name>
<html remote="$host">
<head>
</script>
</head>
<body >
<form enctype='multipart/form-data' action='gostart' method='get' >
<p> <font size='3'> Begin 1:</font></p>
<input type='text' id='command' name='command' value='test.sh' />
<input type='submit' name='action' value='Continue' />
<input type='submit' name='action' value='Cancel' />
<input type='button' onClick='history.go(-1);;' value='Back' />
</form>
</body>
</html>
</request>
@}}
BROWSER
# wait for the user to perform the operation we requested him
read ln
echo "action: " $ln
echo Test 1 Passed
#====================================================
cat << BROWSER
@{{
<request>
<name> Test 2 </name>
<html remote="$host">
<head>
</head>
<body >
<form enctype='multipart/form-data' action='vide://vct' method='get' >
<p> <font size='3'> Test 2: </font></p>
<br></br>
<p> <font size='3'> Execute the esxcfg-scsidev -c command </font></p>
<input type='text' id='command' name='command' value='test2.sh' />
<input type='submit' name='action' value='Continue' />
<input type='submit' name='action' value='Cancel' />
<input type='button' onClick='history.go(-1);;' value='Back' />
</form>
</body>
</html>
</request>
@}}
BROWSER
# wait for the user to perform the operation we requested him
read ln
echo "action: " $ln
echo Test 2 Passed
ASKER
do i need a javascript inside this bash shell script?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Is there a chance it not working because I don't have javascript in the bash shell script?
If you show the page in a browser, the javascript will work
ASKER
Problem was with this limited browser that does not support javascript.
Open in new window