Respuestas

mar. 01, 2007 - 10:32
En este sitio te responden: http://www.esqsoft.com/javascript-hel...
Básicacmente
if (x)
//La variable existe
else
//La variable NO existe
Básicacmente
if (x)
//La variable existe
else
//La variable NO existe

mar. 01, 2007 - 10:38
Otra forma es:
if (typeof (x) == "undefined")
alert("La variable x no existe")
else
alert("La variable x existe")
Esta forma es realmente multibrowser. La anterior solo funciona bien en IE y FireFox. En Opera/Safari /Konkeror/Camino no funciona.
if (typeof (x) == "undefined")
alert("La variable x no existe")
else
alert("La variable x existe")
Esta forma es realmente multibrowser. La anterior solo funciona bien en IE y FireFox. En Opera/Safari /Konkeror/Camino no funciona.

mar. 06, 2007 - 21:20
gracias, gonzalo.
también encontré esta manera de hacer en quomon en inglés: http://www.quomon.com/question_how_to...
también encontré esta manera de hacer en quomon en inglés: http://www.quomon.com/question_how_to...
Añadir Nuevo Comentario