Ver Mensaje Individual
  #7 (permalink)  
Antiguo 12/09/2012, 22:41
ANDRESDD
 
Fecha de Ingreso: julio-2012
Ubicación: Guatemala
Mensajes: 99
Antigüedad: 11 años, 9 meses
Puntos: 2
Respuesta: problemas al enviar datos

bueno separe los dos archivos, uno solo para el formulario y otro solo para el php, ya puse hasta arriba el sessionstart();

<?php
session_start();
require_once("conexion2.php");
if (isset($_POST['ecorreo']) && isset($_POST['clave'])){
$sega = sprintf ("select ".$EMA.", ".$CLA.", ".$NOM.", ".$EST." from ".$US." where ".$EMA."='%s' ", mysql_real_escape_string($_POST['ecorreo'] ) );
$registro=mysql_query($sega);
$reg=mysql_fetch_array($registro);
//echo $reg["$NOM"];
//echo $reg["$CLA"];
$_POST['clave'] =sha1($_POST['clave']);
if (($_POST['ecorreo']==$reg["$EMA"])&&($_POST['clave']==$reg["$CLA"]) && ($reg["$EST"]=='1')){
$_SESSION['usuario']=$reg["$NOM"];
$_SESSION['tiempo']=time();
header("location:y.php");
}
else
header("location:x.html");
}
else
{
header("location:x.html");
}

pero los errores persisten, ahora no tengo codigo html en el archivo