Hi
I have a form that with the the following code:
[code=html]<form method=”post” action=”http://mydomain.org/xxx.php”>
I need to validate two fields within the form and I am using javascripts alert method to do so. However, when I click my Submit button, the form validation is executing and I get an alert on the php page referenced above. I want my alert box to come up on the current window location.
How should I write my javascript validation code? I currently have the following code:
[QUOTE]
<?php if($name == ”)
{echo “<script language=’javascript’>alert(‘You have not entered an name, please try again’)</script>”;}?>
Thanks!