<?php
	include_once('../config.php');  
	include_once('../recharges/recharge_api.php');  
    include_once(ABS_PATH.'/custom_function/default.php');       
     
                
                $stmt=$conn->prepare("select eml,nm,phm,utilities from UI__Rgst    where cuurentId=:cuurentId     ");   
                $stmt->bindValue(':cuurentId',  $_SESSION['userId'] , PDO::PARAM_INT);  
                $stmt->execute(); 
                $UI__Rgst = $stmt->fetch(PDO::FETCH_OBJ);            
                $Email  = $UI__Rgst->eml; 
                
                $PAYWAllet =  GetBalance();
                
                
                
                
                if($UI__Rgst->utilities=="")
                $utili = 0;
                else{
                    $expln =  explode(",",$UI__Rgst->utilities); 
                    $utili = $expln[3];
                }   
                
                
                if( (!isset($_SESSION['userId'])) || ($utili!=1) )
                { 
                    header("Location: ../");
                    die;
                }    
                

	 
			        if(isset($_POST['Recharge'])) 
			        { 
    					 header("Location: mobile1.php?mobile_no=".$_POST['mobile_no']."&operatorPrepaid=".$_POST['operatorPrepaid']."&Operator=".$_POST['Operator']."&operatorPrepaidval=".$_POST['operatorPrepaidval']);
    					 die;
			        }  		    
			         
include_once("../view/dashboard/mobile.php");
?>