PHP - PHP con conexion ADODB

 
Vista:

PHP con conexion ADODB

Publicado por HENRY SUAREZ (2 intervenciones) el 29/06/2011 21:51:22
Tengo el sigueinte INDEX.PHP
<html>
<head>
<title>&lt;. MIPAGINA .&gt;</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript" src="funciones.js"></script>
<link href="CSS/EstilosSitio.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
body {
background-color: #E2E6CA;
}
-->
</style></head>
<div align="center">
<img src="graficos/banner.png">
</div>
<p align="center" class="titulo2">VALIDACION DE USUARIO </p>
<table width="300" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#663300">
<tr>
<td height="47" align="center" bgcolor="#B0C56A" class="Tabla01">
<form name="frm" action="menu.php" method="post" onSubmit="javascript:return checkFields()">
<table width="290" border="0" cellpadding="1" cellspacing="1">
<tr>
<td align="right">Usuario:</td>
<td><input name="Usuar1" type="text" class="textoformas"></td>
</tr>
<tr>
<td align="right">Contrase&ntilde;a:</td>
<td valign="top"><input name="Pass" type="password" class="textoformas"></td>
</tr>
<tr align="center">
<td colspan="2" > <input name="Submit" type="submit" class="textoformas" value="Ingresar">
</td>
</tr>
</table>
</form> </td>
</tr>
</table><br><br>
</body>
</html>

EL ARCHIVO MENU.PHP ES:
<?php
/* $Usuar1 = $_REQUEST['Usuar1'];
$Pass = $_REQUEST['Pass'];
$tipo = $_REQUEST['tipo'];*/
include("conexion.php");
$fallo1=$fallo2="";
$sql= "SELECT A.K_USUARI, A.O_CLAVE FROM AD078MUSUARIO A WHERE A.I_ACTIVO = 'Y' AND A.K_USUARI = :Usuario AND A.O_CLAVE = :Password";
// $sql= "SELECT A.K_USUARI, A.O_CLAVE FROM AD078MUSUARIO A WHERE A.I_ACTIVO = 'Y'";
$result = $db->Execute($sql,array($Usuar1, $Pass));
if ($result === false) die("No conecto en menu.php");
echo $Usuar1; echo $Pass;
?>

CONEXION.PHP ES:

<?php
//Incluir la clase que hace permite conexión a Oracle
include "adodb5/adodb.inc.php";
include('adodb5/tohtml.inc.php');
$db = NewADOConnection('oci8');
$db->debug = true;
//$db->Connect("200.10.10.3", "web", "cac13794682", "LINIX");
$db->Connect("200.10.10.3", "HAS", "HEXUZ", "LINIX");

//La forma mas rapida de acelerar las consultas son colocando las siguientes valores para la conexion
$ADODB_CACHE_DIR='cache_dir/';
$ADODB_COUNTRECS=false;
$ADODB_LANG='es'; //lenguaje para la base de datos documentacion, errores, y algunas otras cosas. :P
$ADODB_FETCH_MODE=ADODB_FETCH_NUM; // O tambien el valor numerico que es 1

?>


NO LOGRO QUE LOS DATOS QUE DIGITO EN EL INDEX,PHP SEAN TOMADOS Y VALIDADOS EN MENU.PHP AL PARECER ES POR EL TIPO DE CARACTERES QUE UTILIZO PERO NO HE LOGRADO ENCONTRAR LA SOLUCION, AGRADEZCO LA AYUDA.
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder
Imágen de perfil de xve
Val: 3.943
Oro
Ha mantenido su posición en PHP (en relación al último mes)
Gráfica de PHP

PHP con conexion ADODB

Publicado por xve (6935 intervenciones) el 29/06/2011 23:30:50
Hola Henry, en vez de utilizar $_REQUEST[] prueba a utilizar $_POST[]

En el inicio de menu.php indica que te muestre el contenido de estas variables, haber si el valor pasa correctamente:
1
2
3
<?php
exit($_POST["Usuar1"]." - ".$_POST["Pas"]);
...

Coméntanos, ok?
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

PHP con conexion ADODB

Publicado por HENRY SUAREZ (2 intervenciones) el 29/06/2011 23:53:40
Buneo la cosa efectivamente tenia que ver con la falta de $_POST, estabamos conectados XVE, gracias por tu atención y colaboración.
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar