Código:
Tal y como esta si me funciona, el campo nombre toma el foco despues de que le doy aceptar al alert.xmlhttp=new ConstructorXMLHttpRequest();
xmlhttp.onreadystatechange=function(){
if (xmlhttp.readyState==4 && xmlhttp.status==200){
document.getElementById("cuerpo").innerHTML=xmlhtt p.responseText;
var frm = document.getElementById('nombre');
alert(frm);
frm.focus();
}
}
xmlhttp.open("POST",openProg, true);
xmlhttp.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xmlhttp.send(queryString);
return false;
Pero si quito el alert, el campo nombre nunca toma el foco y lo mas raro es que no me marca ningun error.
Gracias anticipadas y Saludos


