|
Posted by Jonathan N. Little on 08/04/06 19:15
thomanjl wrote:
> This is my input field code:
>
> <input name="subButton" type="button" value="Cancel"
> onclick="javascript: Response.Redirect URL_HOME />
>
> My problem is the button doesn't redirect to the destined url...any
> ideas??
>
Firstly, what would happen if client has JavaScript disabled, eh?.
Secondly that is not how you do a JavaScript redirect. Thirdly you
should not do this with JavaScript but with server-side scripting.
Not familiar with ASP but in pseudo code, your cancle button should be a
submit button
<form action="receiving.script" method="post">
....
<input type="submit" name="cancel" value="Cancel">
then "receiving.script"
if in POST var cancel exists then
{
redirect header to URL_HOME
}
else
{
process form posted data
}
--
Take care,
Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
Navigation:
[Reply to this message]
|