Tema: Login en PHP
Ver Mensaje Individual
  #1 (permalink)  
Antiguo 05/10/2015, 07:30
javierconesa23
 
Fecha de Ingreso: febrero-2011
Ubicación: Barcelona
Mensajes: 195
Antigüedad: 13 años, 2 meses
Puntos: 1
Login en PHP

hola buenas . tengo un php que conecta con un webservice:
Código PHP:
<!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" dir="ltr" lang="is-IS">

<head profile="http://gmpg.org/xfn/11">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />

<title>NAV Web Service via PHP</title>
</head>
<body>

<?php

define
('USERPWD','128.20.1.1\jconesa:jconesa'); // Sustituir xxx por la contraseña del servidor 
include("NTLMStream.php");  
include(
"NTLMSoapClient.php");
 
stream_wrapper_unregister('http');
stream_wrapper_register('http','NTLMStream') or die("Fallo al registrar protocolo");
$pageURL =  'http://128.20.1.1:7047/DynamicsNav/WS/1%20TPS-N_LAB/Codeunit/WSTrucksAut'// El Web Service 
$params = array();
$params["user"] = "JCONESA"// param1 es el nombre el primer parámetro.
$params["password"] = "12345";
$client = new NTLMSoapClient($pageURL);
stream_wrapper_restore('http');
$result $client->LoginCheck($params); // El método del Web Service 
$numped $result->return_value;
echo 
'CONEXION REALIZADA CON EXITO: '.$numped;
die();

?>


</body>
</html>

BUeno en resumen, esto se conecta a un servidor en windows y se hace login con un ERP.

,mi pregunta es como podria crear un login para que se pudieran autentificar via web