Ejemplo n.º 1
0
		header ("Location: banklogin.php");
	}

	if (!$userTools->login($emailId, $password)){ 
        echo("Login Failed");
		return;
    }

	if (!isset($_SESSION["emailId"])) {
		header ("Location: banklogin.php");
	}



	// Check the balance of the current user
	$balance = AccountUtils::checkBalance($emailId);

	//Check if IBAN already exists and if yes, then return the balance
	$balanceOfTheTargetUser = AccountUtils::checkBalanceIBAN($iban);


	$data = array(
			"senderIban" => AccountUtils::getIBANFromEmail($emailId),
			"receiverIban" => $iban,
			"bic" => $bic,
			"amount" => $amount,
			"description" => "'$description'",
			"userId" => "'$emailId'",
			"date" => "'".date('Y-m-d H:i:s')."'",
			"closingBalance" => $balance,
			"isActive" => $isActive,