Ver Mensaje Individual
  #1 (permalink)  
Antiguo 02/01/2012, 18:06
newbie007
 
Fecha de Ingreso: enero-2012
Mensajes: 26
Antigüedad: 12 años, 4 meses
Puntos: 0
Pregunta Sistema de redireccionamiento de url aayuda

esq he echo un sistema de redireccionamiento de url pero tiene muchos errores
me podrian ayudar a componerlo

formulario de nueva url:
Código:
 <form id="form1" name="form1" method="post" action="id.php">
            <center><label>Link</label>
            <input name="Link" type="text" id="Link" size="70" /></center>
            
                   <br />
                   <br /><center><label>Descripción</label>
                    <input name="des" type="text" id="des" size="70" maxlength="30" /></center><br /><br />
            
                    <label>
                 <center> <input type="submit" name="ok" id="ok" value="Enviar" /></center>
            </label>
        </form>
id.php
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>
<?php
$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.mipage.net/.$archivo</a>";

</body>
</html>