Tema: POST vacio
Ver Mensaje Individual
  #8 (permalink)  
Antiguo 26/02/2011, 13:39
Avatar de memoadian
memoadian
Colaborador
 
Fecha de Ingreso: junio-2009
Ubicación: <?php echo 'México'?>
Mensajes: 3.696
Antigüedad: 14 años, 10 meses
Puntos: 641
Respuesta: POST vacio

bueno para poner highlight se usa ese select que dice highlight al abrirlo te aprece que lenguaje
php, mysql, html, etc, y te resulta esto.

Código PHP:
Ver original
  1. esto :)

luego hay un arror muy simple, las etiquetas <? no son php antes valian pero ahora no

debes poner <?php

luego dejando tu código asi:

me recupera perfectamente la variable.

Código HTML:
Ver original
  1. <form method="post" name="Datos" id="Datos" enctype="multipart/form-data" action="">
  2. <table height="20" border="1" width="55%" align="center">
  3. <tr>
  4. <td><center><img src="logo psicologia.JPG"/></center>
  5. </tr>
  6. <tr>
  7. <td><center><font size="7" color="#000000">Registro de Encuestas</font></td>
  8. </tr>
  9. <tr>
  10. <td align="center">Nombre de la Encuesta: <input type="text" name="tNombre" id="tNombre" />
  11. </tr>
  12. <tr>
  13. <td align="center">Elegir Encuesta: <input type="file" name="tPreguntas" id="tPreguntas" style="width:315px" />
  14. <input type="submit" name="subir" id="subir" value="Subir" />
  15. <input type="button" value="Guardar" onclick="guardar()" /></td>
  16. </tr>
  17. <tr>
  18. <td align="center"><label><font size="5">Estos son los Resultados de las Encuestas hasta el Momento Capturadas</font></label></td>
  19. </tr>
  20. </form>
Código PHP:
Ver original
  1. <?php
  2. @header('Content-Type: text/html;');
  3. $arrDatos = array();
  4. $tTMP = $_FILES['tPreguntas']['tmp_name'];
  5. $campos = array(1 =>'eCodPregunta', 2 => 'tNombre', 3 => 'eCodIdentificador', 4 => 'eCodRespuesta' );
  6.  
  7.  
  8. $tNombre = $_POST['tNombre'];
  9. echo $tNombre;
  10. ?>
Código HTML:
Ver original
  1. </body>
  2. </html>

los tres estan en el mismoarchivo en ese orden