Ver Mensaje Individual
  #7 (permalink)  
Antiguo 02/01/2012, 17:10
newbie007
 
Fecha de Ingreso: enero-2012
Mensajes: 26
Antigüedad: 13 años, 2 meses
Puntos: 0
Respuesta: Colocar un iframe en un echo

Cita:
Iniciado por pateketrueke Ver Mensaje
Caray, ¿nos das permiso de adivinar como has dejado tu código ahora?
Código:
<?
if($_POST[suma]== "4"){
$link = $_POST[Link];
echo "<iframe src=$link width='100%' height='900'></iframe>";
} else{
echo "Responde la suma";
}
?>
asi me sige dando error y ya le puse las llaves (se me abian olvidado)
pero me marca error
Código:
syntax error, unexpected T_LNUMBER in /home/u534012470/public_html/id.php on line 43
llo les puse la parte donde me marcaba error pero si quieren todo el code es este

Código:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Documento sin t&iacute;tulo</title>
</head>

<body>
<?
$archivo = uniqid();
$fp = fopen($archivo, "a");
$string = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Documento sin t&iacute;tulo</title>


</head>

<body>

<form id="form1" name="form1" method="post" action="redirec.php">
<p><a href="http://es.celldorado.com/ES/ADS/118980551" target="_blank" onClick="javascript:boton.disabled=false;">Habilitar botón y abrir publicidad</a></p>
<p>&nbsp;</p>
<h3>Descripción:</h3><p>
<?
$_POST[des]
?></p>
<button id="boton" disabled="true">Aceptar</button> 
<p>
 
</p>
<p> 2+2 =
  <label>
  <input name="suma" type="text" id="textfield" size="5" />
  </label>
</p>
<p>
  <?
if($_POST[suma]== "4"){
$link = $_POST[Link];
echo "<iframe src=$link width='100%' height='900'></iframe>";
} else{
echo "Responde la suma";
}
?>
</p>
<p>&nbsp; </p>
</form>


<p>&nbsp;</p>
</body>
</html>';
$write = fputs($fp, $string);
fclose($fp);  
?>
echo "<a href="$archivo">www.mipagina.net/.$archivo</a>";
</body>
</html>