| Server IP : 127.0.0.1 / Your IP : 216.73.216.48 Web Server : Apache/2.4.58 (Win64) OpenSSL/3.1.3 PHP/8.2.12 System : Windows NT DESKTOP-3H4FHQJ 10.0 build 19045 (Windows 10) AMD64 User : win 10 ( 0) PHP Version : 8.2.12 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : D:/active_xampp_upgrade/cranepay/ |
Upload File : |
<html>
<?php
include('db.php');
session_start();
$user_ip = getenv('REMOTE_ADDR');
$geo = unserialize(file_get_contents("http://www.geoplugin.net/php.gp?ip=$user_ip"));
$city = $geo["geoplugin_city"];
$country = $geo["geoplugin_countryName"];
//echo" mmm $user_ip";
///////////////////////////////////////////////////////////////////////////////////////
$cur_date = date("d");
$cur_month = date("M");
$cur_year = date("Y");
///////////////////////////////////////////////////////////////////////////////////////
?>
<head>
<title>CrinePay</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" type="text/css" href="main_css/login.css" />
<meta name="google-adsense-account" content="ca-pub-4728417548940171"><!--gog ads -->
</head>
<body >
<div id="login_div" onclick="get_focused();" class="main_content_div" >
<div class="main_home_tile" ><img src="main_icon/cp_log.png" width="70px" height="70px" classk="dep_img" style="border-radius:100%;" /></div>
<div class="welcom_title" >Login to CrinePay</div>
<div class="sub_welcom_title" >Send money to your loved ones</div>
<form method="post" >
<!--span class="county_code_lebal" style="margin-top:40px;">Code</span-->
<span class="new_acc_mob_lebal" style="margin-top:40px;">Mobile No. 75*******</span>
<select id="code_input" name="code_input" class="county_code_input" >
<option class="county_code_input" style="margin-top:40px;">+256</option>
<option class="county_code_input" style="margin-top:40px;">+973</option>
<option class="county_code_input" style="margin-top:40px;">+966</option>
</select>
<input name="login_phone" class="new_acc_mob_input" minlength="8" maxlength="9" />
<span class="name_lebal" >Password</span>
<input type="password" name="log_pass" class="name_input" minlength="6" maxlengthk="6" />
<!--input type="number" id="pass_input" onKeyup="check_length();" autofocus class="pass_input" stylek="display:none;" /-->
<?php
if(isset($_POST['login_acc']))
{
$login_phone = $_POST['login_phone'];
$log_pass = $_POST['log_pass'];
$get_user_login ="select * from crane_pay_usertb where user_phone_no='$login_phone' AND user_password='$log_pass' AND account_status !='Delete' ";
$run_get_user_login = mysqli_query($con,$get_user_login);
$check_login = mysqli_num_rows($run_get_user_login);
if($check_login < 1 ){
echo"<div style='float:left;width:100%;height:40px;line-height:40px;font-size:1.2em;text-align:center;color:blue;font-weight:bold;'>Check your password or mobile no.</div>";
}else{
while($row_get_user_login = mysqli_fetch_array($run_get_user_login))
{
$user_id = $row_get_user_login['id'];
$_SESSION['id']=$user_id;
echo"<script>window.open('index', '_self')</script>";
echo"<div style='float:left;width:100%;height:40px;line-height:40px;text-align:center;color:red;font-weight:bold;'>Your password does not match</div>";
}
}
}
?>
<button id="login_acc" name="login_acc" class="login_acc" >Login</button>
</form>
<div class="forgot_pass_div" >or</div>
<button onclick="show_new_acc();" class="register_btn" >Register</button>
<div class="forgot_pass_div" >Forgot Password?</div>
</div>
<div id="create_new_acc_div" class="create_new_acc_div" >
<div class="create_new_acc_title" >New CrinePay account</div>
<form method="post" >
<!--span class="county_code_lebal" style="margin-top:40px;">Code</span-->
<span class="new_acc_mob_lebal" style="margin-top:40px;">Mobile No. 75*******</span>
<select id="code_input" name="code_input" class="county_code_input" >
<option class="county_code_input" style="margin-top:40px;">+256</option>
<option class="county_code_input" style="margin-top:40px;">+973</option>
<option class="county_code_input" style="margin-top:40px;">+966</option>
</select>
<input type="number" id="user_phone_no" name="user_phone_no" class="new_acc_mob_input" minlengthk="9" maxlengthk="9" />
<span class="name_lebal" >First Name</span>
<input type="text" id="fname_input" name="fname_input" class="name_input" minlength="3" />
<span class="name_lebal" >Last Name</span>
<input type="text" id="lname_input" name="lname_input" class="name_input" minlength="3" />
<span class="name_lebal" >Password</span>
<input type="password" id="user_pass" name="user_pass" class="name_input" minlength="6" maxlengthk="6" />
<span class="name_lebal" >Confirm password</span>
<input type="password" id="confirm_pass" name="confirm_pass" class="name_input" minlength="6" maxlengthk="6" />
<div id="error_output" class="error_output" style=''></div>
<?php
if(isset($_POST['add_new_acc']))
{
$country_code = $_POST['code_input'];
$user_phone_no = $_POST['user_phone_no'];
$fname = $_POST['fname_input'];
$lname = $_POST['lname_input'];
$user_pass = $_POST['user_pass'];
$confirm_pass = $_POST['confirm_pass'];
$check_user ="select * from crane_pay_usertb where user_phone_no='$user_phone_no'";
$run_check_user = mysqli_query($con,$check_user);
$check_user_info = mysqli_num_rows($run_check_user);
if($check_user_info >0 ){
echo"<div style='float:left;width:96%;height:40px;line-height:40px;margin-left:2%;text-align:center;color:red;background:#ededed;'>Mobile number already exists.</div>";
?>
<script>
document.getElementById('create_new_acc_div').style.display="block";
document.getElementById('login_div').style.display="none";
</script>
<?php
}else{
$insert_new_acc ="insert into crane_pay_usertb(fname,lname,country_code,user_phone_no,user_password,user_county,user_city,cur_date,cur_month,cur_year,cur_time)
values('$fname','$lname','$country_code','$user_phone_no','$user_pass','$country','$city','$cur_date','$cur_month','$cur_year',CURTIME() )";
$run_new_acc = mysqli_query($con,$insert_new_acc);
if(!$run_new_acc){
echo"<div style='float:left;width:100%;height:40px;line-height:40px;text-align:center;color:red;'>Something went, Try again later.</div>";
}else{
$get_user ="select * from crane_pay_usertb where user_phone_no='$user_phone_no' AND user_password='$user_pass' ";
$run_get_user = mysqli_query($con,$get_user);
while($row_get_user = mysqli_fetch_array($run_get_user))
{
$user_id = $row_get_user['id'];
$_SESSION['id']=$user_id;
$insert_new_bank_acc ="insert into banktb(my_id,country_code,account_no,fname,lname,acc_amount,user_county,user_city,cur_date,cur_month,cur_year,cur_time)
values('$user_id','$country_code','$user_phone_no','$fname','$lname','0','$country','$city','$cur_date','$cur_month','$cur_year',CURTIME() )";
$run_new_bank_acc = mysqli_query($con,$insert_new_bank_acc);
if($run_new_bank_acc){ echo"<script>window.open('index', '_self')</script>";}
}
}
if(isset($_GET['pa_code']))
{
$con = mysqli_connect('localhost','root','2019khalaf','cb_awarddb');
if(! $con){echo"You have not connected to the database.";}
else{
$pro_code = $_GET['pa_code'];
$update_cb_bank ="UPDATE cb_banktb SET cb_coin='33' where my_id='$pro_code' ";
$run_bank_update = mysqli_query($con,$update_cb_bank);
//if($run_cb_bank_acc){ echo"<script>window.open('index', '_self')</script>";}
}
}
}
}
?>
<button id="add_new_acc" name="add_new_acc" class="create_new_acc_btn" style="display:none;" >Create now</button>
</form>
<button id="create_next_btn" onclick="check_new_user_info();" class="create_new_acc_btn" >Next</button>
<div class="forgot_pass_div" >or</div>
<button onclick="show_login();" class="login_acc_btn" >Login</button>
</div>
<?php
echo date("d");
echo date("M");
echo date("Y");
//echo "Today is " . date("l");
?>
<script>
function get_focused()
{
document.getElementById("pass_input").click();
document.getElementById("pass_input").focus();
//alert(44);
}
function check_new_user_info()
{
document.getElementById('error_output').style.display="none";
code_input =document.getElementById('code_input').value;
fname_input =document.getElementById('fname_input').value;
lname_input =document.getElementById('lname_input').value;
user_phone_no =document.getElementById('user_phone_no').value;
user_pass =document.getElementById('user_pass').value;
confirm_pass =document.getElementById('confirm_pass').value;
user_phone_no_leng = user_phone_no.length;
if(code_input =="" || fname_input =='' || lname_input=="" || user_phone_no=="" || user_pass=="" || confirm_pass==""){
document.getElementById('error_output').innerHTML="Please fill all the fields";
document.getElementById('error_output').style.display="block";
}else if(user_pass !== confirm_pass ){
document.getElementById('error_output').innerHTML="Your password does not match";
document.getElementById('error_output').style.display="block";
} else if(code_input=='+973'){
if(user_phone_no_leng !==8){
document.getElementById('error_output').innerHTML="Inavild Mobile number";
document.getElementById('error_output').style.display="block";
}else{
document.getElementById('create_next_btn').style.display="none";
document.getElementById('add_new_acc').style.display="block";
}
}else if(code_input =='+256' || code_input =='+966' ){
if(user_phone_no_leng !==9){
document.getElementById('error_output').innerHTML="Inavild Mobile number";
document.getElementById('error_output').style.display="block";
}else{
document.getElementById('create_next_btn').style.display="none";
document.getElementById('add_new_acc').style.display="block";
}
}
}
function check_length()
{
pass_input = document.getElementById('pass_input').value;
pass_input_leng = pass_input.length;
if(pass_input_leng == 1)
{
document.getElementById('pass_leng1').style="background:#fff;";
} else if(pass_input_leng < 1){
document.getElementById('pass_leng1').style="border:2px solid #fff;";
}
if(pass_input_leng == 2)
{
document.getElementById('pass_leng2').style="background:#fff;";
}else if(pass_input_leng < 2){
document.getElementById('pass_leng2').style="border:2px solid #fff;";
}
if(pass_input_leng == 3)
{
document.getElementById('pass_leng3').style="background:#fff;";
}else if(pass_input_leng < 3){
document.getElementById('pass_leng3').style="border:2px solid #fff;";
}
if(pass_input_leng == 4)
{
document.getElementById('pass_leng4').style="background:#fff;;";
}else if(pass_input_leng < 4){
document.getElementById('pass_leng4').style="border:2px solid #fff;";
}
if(pass_input_leng == 5)
{
document.getElementById('pass_leng5').style="background:#fff;;";
}else if(pass_input_leng < 5){
document.getElementById('pass_leng5').style="border:2px solid #fff;";
}
if(pass_input_leng == 6)
{
document.getElementById('pass_leng6').style="background:#fff;;";
gulawo_olugi();
}
}
function gulawo_olugi()
{
document.getElementById('login_acc').click();
//alert(4343)
}
function show_new_acc()
{
document.getElementById('create_new_acc_div').style.display="block";
document.getElementById('login_div').style.display="none";
//alert(4353);
}
function show_login()
{
document.getElementById('login_div').style.display="block";
document.getElementById('create_new_acc_div').style.display="none";
//alert(4353);
}
</script>
</body>
</html>