Ver Mensaje Individual
  #1 (permalink)  
Antiguo 20/12/2005, 10:16
ane_aaron
 
Fecha de Ingreso: julio-2005
Ubicación: Mexico
Mensajes: 140
Antigüedad: 18 años, 9 meses
Puntos: 0
Obtener valor desde un iframe

Hola que tal!!.

Se puede extraer un valor desde un iframe? Explico:
Tengo esta pagina:

Código HTML:
<html>
<head>
<script language="JavaScript" type="text/javascript">
  function ver(){
    var oFrame = document.getElementById('cat');
    alert(oFrame.document.getElementById('dato').value);
  }
</script>
</head>

<body>
<form id="forma">

    <iframe src="contenido.php" id="cat" width="100%"></iframe>
    <input type="button" value="ver" onclick="return ver()">  

</form>
</body>
</html> 
El contenido del iframe es este:

Código HTML:
<html>
<body>
<form id="forma">
 
  <input type="hidden" id="dato" value="Hola mundo!!">
 
</form>
</body>
</html> 
Y al pincharle no me muestra nada
¿Si se puede hacer algo smejante?
__________________
SELECT * FROM LA_VIDA