Mi codigo:
Código:
<script> function validateForm() { var x=document.forms["myForm"]["busca"].value; if (x==null || x=="") { alert("Ingrese usuario"); return false; } } function validateForm2(){ window.open('', 'popup', 'width = 1200, height = 180000000, scrollbars=YES'); } </script>
Código HTML:
<p> <form name ="myForm" method ="post" action="busqueda1.php" id="cdr" target="popup" onsubmit="validateForm();validateForm2()"> <div id="buscar_usuario"><h3>BUSCAR USUARIO</h3></div> <input name="busca" type="text" id="busqueda"> <input type="submit" name="Submit" value="buscar" /> </p> </form>