Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require_once('lib/class.phpwsdl.php');
- ini_set('soap.wsdl_cache_enabled',0);
- PhpWsdl::$CacheTime=0;
- if(isset($_SESSION["email"])) {
- header('location: index.php');
- }
- if($_POST){
- controllaLogin();
- }
- function controllaLogin(){
- $username = $_POST["username"];
- $password = $_POST["password"];
- $wsdl = "http://localhost/SAED/lib/cache/server.wsdl";
- $soap = new SoapClient($wsdl);
- global $risposta;
- $risposta = $soap->controlla_login($username,$password);
- if($risposta[0] == "Login verificato!"){
- session_start();
- $_SESSION['email'] = $risposta[1];
- $_SESSION['categoria'] = $risposta[2];
- header('location: index.php');
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement