<?php
session_start();
// print_r($_SESSION);
// exit;

include "mconnect.php";
include "website_functions.php";
if(isset($_SESSION['mastersession']) && $_SESSION['mastersession']!="" && isset($_SESSION['account_id']) && $_SESSION['account_id']!="" && isset($_SESSION['x_currencyid']) && $_SESSION['x_currencyid']!="")
{
   $user_id = $_SESSION['mastersession'];
   $currency_id = $_SESSION['x_currencyid'];
   $account_id = $_SESSION['account_id'];
   
   $website_url=website_settingdata('x_weburl');
   
    if(isset($_POST['x_idss']) && $_POST['x_idss']!="" && isset($_POST['x_currencyid']) && $_POST['x_currencyid']!="")
   {
      $_SESSION["account_id"] = $_POST['x_idss'];
      $_SESSION["currency_id"] = $_POST['x_currencyid'];
	  
   }
   
   if(isset($_SESSION['account_id']) && $_SESSION['account_id']!=""  && isset($_SESSION['currency_id']) && $_SESSION['currency_id']!="")
   {
	  // x_currencyid
	    $account_id = $_SESSION['account_id'];
	    $currency_id = $_SESSION['currency_id'];
	
   }
   if(isset($_POST['loan_id'])&& $_POST['loan_id']!=""){
     $_SESSION['loan_id'] = $_POST['loan_id'];
   
    }
	if(isset($_SESSION['loan_id']) && $_SESSION['loan_id']!="" )
   {
	  
	   $loan_id = $_SESSION['loan_id'];

   }
   
   if(isset($_POST['inv_id'])&& $_POST['inv_id']!="")
   {
     $_SESSION['inv_id'] = $_POST['inv_id'];
	
    }
	if(isset($_SESSION['inv_id']) && $_SESSION['inv_id']!="" )
   {
	  // x_currencyid
	   $inv_id = $_SESSION['inv_id'];
       
   }
  
  
  
}
else
{
	$website_url=website_settingdata('x_weburl');
    header("location:../index.php");	
    exit();
	
}
?>
