all changes done :suseendhiran
This commit is contained in:
parent
815efbda6e
commit
b343185aa1
@ -327,6 +327,7 @@ class Admin_controller extends BaseController
|
||||
$userdata['userdata'] = $this->dModel->getLoggedInUserData(session()->get('logged_user'));
|
||||
$data['creditsData'] = $this->creditsModel->select('member_credits.* , member.name as member_name ')
|
||||
->join('member', 'member_credits.member_id = member.id', 'left')
|
||||
->orderBy('member_credits.created_at' , 'desc')
|
||||
->findAll();
|
||||
echo view('layout/header',$userdata);
|
||||
echo view('transactions_list',$data);
|
||||
@ -338,6 +339,7 @@ class Admin_controller extends BaseController
|
||||
$creditsData = $this->creditsModel->select('member_credits.* , member.name as member_name ')
|
||||
->join('member', 'member_credits.member_id = member.id', 'left')
|
||||
->where('md5(member_credits.member_id)', $member_id )
|
||||
->orderBy('member_credits.created_at' , 'desc')
|
||||
->findAll();
|
||||
$output = '<div class="table-responsive"><table class="table mb-0"><thead class="thead-light"><tr><th>Date</th><th>Points</th><th>Cost</th><th>Pack / Indidual</th></tr></thead><tbody>';
|
||||
foreach ($creditsData as $row) {
|
||||
|
||||
@ -78,6 +78,7 @@ class Cart_controller extends BaseController
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->session->set('user_token',$token);
|
||||
$data['token'] = $token;
|
||||
|
||||
$data['primary_id'] = $this->request->getVar('id');
|
||||
@ -141,7 +142,10 @@ class Cart_controller extends BaseController
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->index();
|
||||
$val['token'] = '';
|
||||
$val['msg'] = 'Your cart is empty';
|
||||
echo view('cart.php',$val);
|
||||
// $this->index();
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -163,7 +167,10 @@ class Cart_controller extends BaseController
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->index();
|
||||
$val['token'] = $this->session->get('logged_user');
|
||||
$val['msg'] = 'Your cart is empty';
|
||||
echo view('cart.php',$val);
|
||||
// $this->index();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -173,16 +180,30 @@ class Cart_controller extends BaseController
|
||||
if (!session()->has('logged_user'))
|
||||
{
|
||||
$tokendata = $this->Cart_token_model->where('md5(token)', $token )->find();
|
||||
if($tokendata)
|
||||
{
|
||||
$data['token'] = $tokendata[0]['token'];
|
||||
$data['pack_data'] = $this->credits_pack();
|
||||
echo view('membership.php',$data);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->index();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$tokendata = $this->cartModel->where('md5(member_id)', $token )->findAll();
|
||||
$data['token'] = $tokendata[0]['member_id'];
|
||||
$data['pack_data'] = $this->credits_pack();
|
||||
echo view('membership.php',$data);
|
||||
if ($tokendata)
|
||||
{
|
||||
$data['token'] = $tokendata[0]['member_id'];
|
||||
$data['pack_data'] = $this->credits_pack();
|
||||
echo view('membership.php',$data);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->index();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -94,7 +94,8 @@ class Member_controller extends BaseController
|
||||
}
|
||||
}
|
||||
|
||||
return view('member_login');
|
||||
//return view('member_login');
|
||||
return view('myaccount');
|
||||
}
|
||||
|
||||
public function logout()
|
||||
@ -276,12 +277,12 @@ class Member_controller extends BaseController
|
||||
$this->session->setTempdata('email',$data[0]['email'],3);
|
||||
}
|
||||
$this->session->setTempdata('mail_success', "OTP verification sucessfully",3);
|
||||
return view('set_password.php');
|
||||
return view('changepassword.php');
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->session->setTempdata('error', "You entered wrong OTP.Please retry",3);
|
||||
return view('forgot_password.php');
|
||||
return view('forgot_password_otp.php');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -269,11 +269,12 @@ class PaymentController extends BaseController
|
||||
if( $transaction_id != null)
|
||||
$memberCredits = $this->creditsModel->where('transaction_id', $transaction_id )
|
||||
->where('member_id', session()->get('logged_user'))
|
||||
->select('package_name','credit_points')
|
||||
->select('package_name')
|
||||
->selectSum('credit_points', 'credit_points')
|
||||
->selectSum('cost', 'cost')
|
||||
->selectCount('package_name', 'pack_count')
|
||||
->groupBy('package_name')->findAll();
|
||||
|
||||
// print_r($memberCredits);die();
|
||||
$sendmail_controller = new Sendmail_controller();
|
||||
$sendmail_controller->index(session()->get('logged_user_email') , null , 5);
|
||||
$Subtotal = 0;
|
||||
|
||||
@ -237,7 +237,7 @@ class Sendmail_controller extends BaseController
|
||||
$this->session->setTempdata('user',"member",3);
|
||||
if($this->request->getmethod() == 'get')
|
||||
{
|
||||
return view('forgot_password.php');
|
||||
return view('forgot_password_otp.php');
|
||||
}
|
||||
else if($this->request->getmethod() == 'post')
|
||||
{
|
||||
|
||||
@ -30,6 +30,7 @@
|
||||
|
||||
<?php
|
||||
$cost_sum = 0;
|
||||
if (isset($tokendata)) {
|
||||
foreach ($tokendata as $key => $value) { ?>
|
||||
|
||||
|
||||
@ -55,8 +56,8 @@
|
||||
echo $pack_id[$key]['count'];
|
||||
}
|
||||
?>" title="Qty" size="4" min="1" max="" step="1" placeholder="" inputmode="numeric" autocomplete="off"/>
|
||||
<button type="button" class="plus"><i class="fa fa-angle-up"></i></button>
|
||||
<button type="button" class="minus"><i class="fa fa-angle-down"></i></button>
|
||||
<!-- <button type="button" class="plus"><i class="fa fa-angle-up"></i></button>
|
||||
<button type="button" class="minus"><i class="fa fa-angle-down"></i></button> -->
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-2 text-right-price">
|
||||
@ -65,10 +66,16 @@
|
||||
<div class="remove-product"><a href="<?= base_url('/remove_product/').md5($pack_id[$key]['id']); ?>">Remove</a></div>
|
||||
</div>
|
||||
</div>
|
||||
<?php $cost_sum = $cost_sum +$value['cost'] * $pack_id[$key]['count']; } ?>
|
||||
<?php $cost_sum = $cost_sum +$value['cost'] * $pack_id[$key]['count']; } } ?>
|
||||
|
||||
<!-- cart empty msg -->
|
||||
<?php if (isset($msg)) { echo '<center>'.$msg.'</center>'; }?>
|
||||
|
||||
|
||||
|
||||
<?php if (isset($tokendata)) { ?>
|
||||
<!-- Product Sub total-->
|
||||
<div class="row sub-total border-bottom pt-4">
|
||||
<div class="row sub-total border-bottom pt-4 pb-4">
|
||||
<div class="col-12">
|
||||
<div class="row">
|
||||
<div class="col-3 pb-4">
|
||||
@ -80,17 +87,29 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Product Tax-->
|
||||
<!-- Product Tax-->
|
||||
<div class="row">
|
||||
<div class="col-3 pb-4">
|
||||
<div class="subtotal-label">Taxes</div>
|
||||
</div>
|
||||
<div class="col-9 ">
|
||||
<input id="pst" value="<?= $pst[0]['value'] ?>" type="hidden">
|
||||
<input id="gst" value="<?= $gst[0]['value'] ?>" type="hidden">
|
||||
<div class="subtotal-price text-right-price pst"><span class="price-symbol">$</span><?= $cost_sum * $pst[0]['value'] / 100; ?></div>
|
||||
<div class="subtotal-price text-right-price gst"><span class="price-symbol">$</span><?= $cost_sum * $gst[0]['value'] / 100; ?></div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<div class="subtotal-label">Taxes</div>
|
||||
</div>
|
||||
<div class="col-lg-3"></div>
|
||||
<div class="col-lg-1 text-end">
|
||||
<div class="taxes pst label">PST(7%)</div>
|
||||
</div>
|
||||
<div class="col-lg-2 text-end">
|
||||
<input id="pst" value="<?= $pst[0]['value'] ?>" type="hidden">
|
||||
<div class="subtotal-price text-right-price pst"><span class="price-symbol">$</span><?= $cost_sum * $pst[0]['value'] / 100; ?></div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
</div>
|
||||
<div class="col-lg-3"></div>
|
||||
<div class="col-lg-1 text-end">
|
||||
<div class="taxes gst label">GST(5%)</div>
|
||||
</div>
|
||||
<div class="col-lg-2 text-end">
|
||||
<input id="gst" value="<?= $gst[0]['value'] ?>" type="hidden">
|
||||
<div class="subtotal-price text-right-price gst"><span class="price-symbol">$</span><?= $cost_sum * $gst[0]['value'] / 100; ?></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -103,7 +122,7 @@
|
||||
<div class="subtotal-price text-right-price total"><span class="price-symbol">$</span><?= round($cost_sum + $cost_sum * $pst[0]['value'] / 100 + $cost_sum * $gst[0]['value'] / 100 , 2 ) ?></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php } ?>
|
||||
<!-- Product Sub total-->
|
||||
<div class="row pt-4 pb-4">
|
||||
<div class="col-3 pb-4">
|
||||
|
||||
70
app/Views/changepassword.php
Normal file
70
app/Views/changepassword.php
Normal file
@ -0,0 +1,70 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>Change Password - Golf Evolution</title>
|
||||
<meta charset="UTF-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="<?= base_url()."/public/"; ?>assets/member_images/favicon.png" sizes="192x192" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<link rel="stylesheet" href="<?= base_url()."/public/"; ?>assets/member_css/front-style.css">
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Comfortaa:wght@300;400;500;600;700&family=DM+Sans:wght@400;500;700&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.4/jquery.min.js"></script>
|
||||
</head>
|
||||
<body class="forgetpassword">
|
||||
<?php include 'member_layout/header.php' ?>
|
||||
<section class="pt-5 pb-5">
|
||||
<div class="container">
|
||||
<div class="recovery-account">
|
||||
<h1>Set Password</h1>
|
||||
<form method="post" action="<?= base_url()."update_password"; ?>" role="form" class="parsley-examples">
|
||||
<input id="id" type="hidden" value="<?= session()->getTempdata('id'); ?>" name="id">
|
||||
|
||||
<?php if(session()->getTempdata('mail_success')):?>
|
||||
<div class="alert alert-success" >
|
||||
<?= session()->getTempdata('mail_success'); ?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
|
||||
|
||||
<?php if(session()->getTempdata('error')):?>
|
||||
<div class="alert alert-danger" >
|
||||
<?= session()->getTempdata('error'); ?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 mb-3">
|
||||
<label for="email">Email</label>
|
||||
<input type="email" id="email" class="form-control" value="<?= session()->getTempdata('email'); ?>" readonly>
|
||||
</div>
|
||||
<div class="col-12 mb-4">
|
||||
<label for="email">Password</label>
|
||||
<input type="password" id="hori-pass1" class="form-control"
|
||||
pattern="(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[^a-zA-Z0-9])(?!.*\s).{8,}"
|
||||
title="Must contain at least one number and one uppercase and lowercase letter, and at least 8 or more characters"
|
||||
placeholder="Enter password" name="password" required>
|
||||
</div>
|
||||
<div class="col-12 mb-4">
|
||||
<label for="email">Confirm Password</label>
|
||||
<input type="password" data-parsley-equalto="#hori-pass1" class="form-control" placeholder="Enter confirm password" required>
|
||||
</div>
|
||||
</div>
|
||||
<button type="submit" class="forget-submit">Submit</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<?php include 'member_layout/footer.php' ?>
|
||||
</body>
|
||||
<!-- Plugin js-->
|
||||
<script src="<?= base_url()."/public"; ?>/assets/libs/parsleyjs/parsley.min.js"></script>
|
||||
|
||||
<!-- Validation init js-->
|
||||
<script src="<?= base_url()."/public"; ?>/assets/js/pages/form-validation.init.js"></script>
|
||||
</html>
|
||||
107
app/Views/forgot_password_otp.php
Normal file
107
app/Views/forgot_password_otp.php
Normal file
@ -0,0 +1,107 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>Forget Password - Golf Evolution</title>
|
||||
<meta charset="UTF-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="<?= base_url()."/public/"; ?>assets/member_images/favicon.png" sizes="192x192" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<link rel="stylesheet" href="<?= base_url()."/public/"; ?>assets/member_css/front-style.css">
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Comfortaa:wght@300;400;500;600;700&family=DM+Sans:wght@400;500;700&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.4/jquery.min.js"></script>
|
||||
<script src="<?= base_url()."/public"; ?>/assets/member_js/ajax.js"></script>
|
||||
</head>
|
||||
<body class="forgetpassword">
|
||||
<?php include 'member_layout/header.php' ?>
|
||||
<section class="pt-5 pb-5">
|
||||
<div class="container">
|
||||
<div class="recovery-account">
|
||||
<h1>Account Recovery</h1>
|
||||
<form method="post" action="<?php echo base_url();?>change_password_form" method="post">
|
||||
<input type="hidden" id="verify_otp" name="verify_otp" value="">
|
||||
<input type="hidden" id="user" value="<?= session()->getTempdata('user'); ?>">
|
||||
|
||||
<div id="alert1"></div>
|
||||
<?php if(session()->getTempdata('error')):?>
|
||||
<div class="alert alert-danger" id="alert">
|
||||
<?= session()->getTempdata('error'); ?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 mb-3">
|
||||
<label for="email">Email Address</label>
|
||||
<input type="email" id="email" name="email" class="form-control" placeholder="Enter your email id">
|
||||
</div>
|
||||
<div class="col-12 mb-4 disable" id="disable">
|
||||
<label for="email">OTP</label>
|
||||
<input type="text" id="otp" name="otp" class="form-control" placeholder="OTP">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group mb-0 text-center" id="re-sub">
|
||||
<button type="" id="submit1" class="forget-submit">Get OTP</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<?php include 'member_layout/footer.php' ?>
|
||||
</body>
|
||||
|
||||
<script>
|
||||
// jQuery autohide element after 5 seconds
|
||||
$('#alert').delay(3000).fadeOut('slow');
|
||||
// This will disable just the div
|
||||
$(".disable").hide();
|
||||
|
||||
$(document).on('click','#submit1',function(){
|
||||
$('#alert1').html('Please wait...');
|
||||
var email = $("#email").val();
|
||||
var url;
|
||||
var user_role = $('#user').val();
|
||||
|
||||
if ($('#user').val() == 'member') { url = "<?php echo base_url();?>forgot_password" }
|
||||
else { url = "<?php echo base_url();?>user_forgot_password" }
|
||||
$.ajax({
|
||||
type: "post",
|
||||
url: url,
|
||||
data: { email : email },
|
||||
json: true,
|
||||
success: function(response) {
|
||||
response = jQuery.parseJSON(response);
|
||||
if (response.status == "success")
|
||||
{
|
||||
$('#alert1').html('');
|
||||
$(".disable").show();
|
||||
$('#verify_otp').val(response.otp);
|
||||
$("#re-sub").html('<button class="btn btn-primary btn-block" type="submit"> Submit </button>');
|
||||
window.stop();
|
||||
}
|
||||
else
|
||||
{
|
||||
console.log(user_role);
|
||||
$('#alert1').html('');
|
||||
$('#alert1').addClass('alert alert-danger');
|
||||
if (user_role == 'member')
|
||||
{
|
||||
$('#alert1').html('Email is not verified.please check your mail.');
|
||||
}
|
||||
else
|
||||
{
|
||||
$('#alert1').html('Invalid email.');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
},
|
||||
error: function(jqXHR, textStatus, err) { alert('text status '+textStatus+', err '+err) }
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</html>
|
||||
@ -23,8 +23,12 @@
|
||||
<div class="col-lg-5 header2">
|
||||
<ul>
|
||||
<li><a href="https://golfevolutionkelowna.ca/about-us/">About Us</a></li>
|
||||
<li><a href="#" class="nav-button"><img src="<?= base_url()."/public"; ?>/assets/member_images/button-logo.png" width="20" height="20">
|
||||
<li><a href="<?php if(session()->has('logged_user')) { echo base_url()."/member_home"; }else{ echo base_url(); } ?>"
|
||||
class="nav-button"><img src="<?= base_url()."/public"; ?>/assets/member_images/button-logo.png" width="20" height="20">
|
||||
<?php if(session()->has('logged_user')) { echo session()->get('logged_user_name'); }else{ ?>MEMBER ACCESS<?php } ?></a></li>
|
||||
<li><a href="<?php if(session()->has('logged_user')) { echo base_url()."view_cart/".md5(session()->get('logged_user')).""; }else{ echo base_url()."view_cart/".md5(session()->get('user_token')).""; } ?>"
|
||||
class="cart-menu" title="View Cart"><img src="<?= base_url()."/public"; ?>/assets/member_images/header-cart-icon.png" width="28" height="25"/></a></li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -36,7 +36,7 @@
|
||||
<th>Name</th>
|
||||
<th>Mobile</th>
|
||||
<th>Email</th>
|
||||
<th>Address</th>
|
||||
<!-- <th>Address</th> -->
|
||||
<th>Status</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
@ -50,7 +50,7 @@
|
||||
<td><?php echo $row['name'];?></td>
|
||||
<td><?php echo $row['mobile'];?></td>
|
||||
<td><?php echo $row['email'];?></td>
|
||||
<td><?php echo $row['address'].",".$row['city_name'].",".$row['state_name'].",".$row['country_name']." - ".$row['pincode'].",";?></td>
|
||||
<!-- <td><?php echo $row['address'].",".$row['city_name'].",".$row['state_name'].",".$row['country_name']." - ".$row['pincode'].",";?></td> -->
|
||||
<td><?php if($row['is_active'] == 1){ echo "Active"; }else{ echo "Deactive"; }?></td>
|
||||
<td><a href="<?= base_url() ?>member_edit/<?php echo md5($row['id']);?>"><i class="mdi mdi-lead-pencil" style="font-size:18px;"></i></a>
|
||||
<?php if ($row['is_active'] == 1) { ?>
|
||||
|
||||
132
app/Views/myaccount.php
Normal file
132
app/Views/myaccount.php
Normal file
@ -0,0 +1,132 @@
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>My Account - Golf Evolution</title>
|
||||
<meta charset="UTF-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="<?= base_url()."/public"; ?>/assets/member_images/favicon.png" sizes="192x192" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<link rel="stylesheet" href="<?= base_url()."/public"; ?>/assets/member_css/front-style.css">
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Comfortaa:wght@300;400;500;600;700&family=DM+Sans:wght@400;500;700&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.4/jquery.min.js"></script>
|
||||
<script>
|
||||
function check_if_exists() {
|
||||
|
||||
var email = $("#email").val();
|
||||
$.ajax({
|
||||
type:"post",
|
||||
url: "<?php echo base_url(); ?>/check_if_mail_exists",
|
||||
data:{ email:email , table : 'member'},
|
||||
success:function(response)
|
||||
{
|
||||
if (response == true)
|
||||
{
|
||||
alert("This mail id already exists");
|
||||
$("#email").val('');
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<?php include 'member_layout/header.php' ?>
|
||||
|
||||
<section class="login pt-5 pb-5">
|
||||
<div class="container">
|
||||
<div class="account-width mb-4" id="myaccount">
|
||||
<div class="form-container sign-up-container">
|
||||
<form method="post" action="<?= base_url()."register"; ?>" role="form" class="parsley-examples">
|
||||
<h1>Create Account</h1>
|
||||
<div class="row">
|
||||
<div class="col-12 mb-3">
|
||||
<label for="username">Username</label>
|
||||
<input type="text" class="form-control" required parsley-type="text" name="name" placeholder="Enter your username" id="username"/>
|
||||
</div>
|
||||
<div class="col-12 mb-3">
|
||||
<label for="loginemail">Email Id</label>
|
||||
<input type="email" class="form-control" required parsley-type="email" name="email" placeholder="Enter your email id" onchange="check_if_exists();" id="loginemail"/>
|
||||
</div>
|
||||
<div class="col-12 mb-3">
|
||||
<label for="mobile">Mobile Number</label>
|
||||
<input type="tel" class="form-control" data-parsley-type="number" name="mobile" placeholder="Enter your mobile number" id="mobile"/>
|
||||
</div>
|
||||
</div>
|
||||
<button class="signup-btn" type="submit">Register</button>
|
||||
</form>
|
||||
</div>
|
||||
<div class="form-container sign-in-container">
|
||||
<form method="post" action="<?= base_url(); ?>">
|
||||
<h1>Sign in</h1>
|
||||
|
||||
<?php if(session()->getTempdata('mail_success')):?>
|
||||
<div class="alert alert-success" >
|
||||
<?= session()->getTempdata('mail_success'); ?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
|
||||
|
||||
<?php if(session()->getTempdata('error')):?>
|
||||
<div class="alert alert-danger" >
|
||||
<?= session()->getTempdata('error'); ?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12 mb-3">
|
||||
<label for="regemail">Email or Username</label>
|
||||
<input type="email" name="email" id="emailaddress" required="" value="gowthamceline46@gmail.com" placeholder="Email" />
|
||||
</div>
|
||||
<div class="col-12 mb-3">
|
||||
<label for="newpassword">Password</label>
|
||||
<input type="password" id="password" name="password" value="admin" placeholder="Password" />
|
||||
</div>
|
||||
</div>
|
||||
<button class="signin-btn" type="submit">Login In</button>
|
||||
<a href="<?= base_url()."forgot_password"; ?>" class="forget-pwd">Forgot your password?</a>
|
||||
</form>
|
||||
</div>
|
||||
<div class="overlay-container">
|
||||
<div class="login-overlay">
|
||||
<div class="overlay-panel overlay-left">
|
||||
<h1>Welcome Back!</h1>
|
||||
<p>To keep connected with us please login with your personal info</p>
|
||||
<button class="login-btn" id="signIn">Sign In</button>
|
||||
</div>
|
||||
<div class="overlay-panel overlay-right">
|
||||
<h1>Hello, Friend!</h1>
|
||||
<p>Enter your personal details and start playing with us</p>
|
||||
<button class="login-btn" id="signUp">Sign Up</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<?php include 'member_layout/footer.php' ?>
|
||||
|
||||
<script>
|
||||
const signUpButton = document.getElementById('signUp');
|
||||
const signInButton = document.getElementById('signIn');
|
||||
const container = document.getElementById('myaccount');
|
||||
|
||||
signUpButton.addEventListener('click', () => {
|
||||
container.classList.add("right-panel-active");
|
||||
});
|
||||
signInButton.addEventListener('click', () => {
|
||||
container.classList.remove("right-panel-active");
|
||||
});
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@ -37,7 +37,7 @@
|
||||
<th>Mobile</th>
|
||||
<th>Email</th>
|
||||
<th>Role</th>
|
||||
<th>Address</th>
|
||||
<!-- <th>Address</th> -->
|
||||
<th>Status</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
@ -52,7 +52,7 @@
|
||||
<td><?php echo $row['mobile'];?></td>
|
||||
<td><?php echo $row['email'];?></td>
|
||||
<td><?php echo $row['role'];?></td>
|
||||
<td><?php echo $row['address'].",".$row['city_name'].",".$row['state_name'].",".$row['country_name']." - ".$row['pincode'].",";?></td>
|
||||
<!-- <td><?php echo $row['address'].",".$row['city_name'].",".$row['state_name'].",".$row['country_name']." - ".$row['pincode'].",";?></td> -->
|
||||
<td><?php if($row['is_active'] == 1){ echo "Active"; }else{ echo "Deactive"; }?></td>
|
||||
<td><a href="<?= base_url() ?>user_edit/<?php echo md5($row['id']);?>"><i class="mdi mdi-lead-pencil" style="font-size:18px;"></i></a>
|
||||
<?php if ($row['is_active'] == 1) { ?>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user