Ver Mensaje Individual
  #1 (permalink)  
Antiguo 11/02/2010, 13:18
Avatar de Esfinge02
Esfinge02
 
Fecha de Ingreso: septiembre-2008
Ubicación: Cd. Victoria Tam
Mensajes: 162
Antigüedad: 15 años, 6 meses
Puntos: 2
Pregunta Problemas con los resultado

buenas, eme aquí de nuevo, primero agradezco su ayuda con todos los temas en que me an ayudado y aquí traigo uno nuevo, XD

es un mero formulario pero cuando lo mando ejecutar simplemente ase nada, si alguien tiene alguna idea se los agrade seria.

Código PHP:
<?php 
//Getting  lists
require ("_cls/cls_mysqlData.php");
require (
"_cls/cls_Login.php");
$usu "";
$pass "";
if(isset(
$_POST["txtusu"])){$usu $_POST["txtusu"];}
if(isset(
$_POST["txtpass"])){$pass $_POST["txtpass"];}
if(isset(
$_POST["txtusu"])){$Login getLogin($usu,$pass);}
echo 
$usu.'<br/>'.$pass;
?>

<!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>Sistema de Seguimiento a Apoyos Comprometidos</title>
<script language="javascript" type="text/javascript" src="js/jquery.js"></script>
<script language="javascript" type="text/javascript" src="js/jquery.form.js"></script>
</head>
<body>
<div id="page_content" style="height:230px;">                

<form action="login.php" method="post">
    <table width="100%" border="0" style="background-position:inherit;">
        
        <tr>
            <td style="height: 62px;" colspan="2"><p style="text-align: center; background-position:top; font-size: 14pt; font-family: Arial">
                Sistema de Compromisos</p>
            </td>
        </tr>
        
        <tr>
            <td style="text-align: right; height: 40px;">
                &nbsp; *Nombre de Usuario:&nbsp;
            </td>
            <td style="height: 40px">
                &nbsp;<input name="txtusu" type="text" maxlength="20" id="Text1"/>
            </td>
        </tr>
        
        <tr>
            <td style="text-align: right; height: 40px;">
                &nbsp; *Contraseña:&nbsp;
            </td>
            <td style="height: 40px">
                &nbsp;<input id="txtpass" name="txtpass" type="password" maxlength="10" /></td>
        </tr>
        
        <tr>
            <td colspan="2" align="center">
                <input type="submit" value="Accesar" id="submit" name="submit" />
            </td>
        </tr>
    </table>
</form>
</div>
</body>
</html>
y aqui el archivo de cls_login
Código PHP:
<?php
    session_start
();
    function 
getLogin($usu$pass){
        
$usu $usu;
        
$pass $pass;
        
$db = new db();
        
$Con $db->query("SELECT * FROM `usario` where USUARIO = '".$usu."' and password = '".$pass."'");
        
//echo ("SELECT * FROM `usario` where USUARIO = '".$usu."' and password = '".$pass."'");
        //echo $Con;
        //exit();
        
$ArrSol $db->fetch_array($Con);
            
$_SESSION['USUARIO'] = "";
            
$_SESSION['COMICION'] = "";
            
$_SESSION['NOMBRE'] = "";
            
$_SESSION['TIPO'] = "";
            
$_SESSION['USUARIO'] = $ArrSol["USUARIO"];
            
$_SESSION['COMICION'] = $ArrSol["comicion"];
            
$_SESSION['NOMBRE'] = $ArrSol["NOMBRE"].' '.$ArrSol["AP"].' '.$ArrSol["AP"];
            
$_SESSION['TIPO'] = $ArrSol["tipo"];
        unset(
$db$Con$ArrSol);
        return 
$_SESSION['USUARIO'];
        
        if (isset(
$_SESSION['USUARIO'])){header("Location: [index.php]");}
        else{
header("Location: [login.php?error=1]");}
    }
?>
__________________
La ignorancia es una bendición o un privilegio, yo lo siento programadores