@UltimaterJun 24.2005 — #That's some really corrupted code you have there. Let me show you a simple example. <i> </i><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd" > <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <meta http-equiv="Content-Script-Type" content="text/javascript"> <title>Example</title> [color=royalblue]<script type="text/javascript"> function checkForm(f){ var fn=f.firstName.value var ln=f.lastName.value if(fn!=""&&ln!=""){alert("form submits");return true} alert("blanks field(s) detected!");return false } </script>[/color] <body> [color=royalblue]<form action="#" onsubmit="checkForm(this)"> First Name:<input type="text" name="firstName"><br> Last Name:<input type="text" name="lastName"> <input type="submit" value="submit form"> </form>[/color] </body> </html>