-
Notifications
You must be signed in to change notification settings - Fork 1
/
update_wallet.php
134 lines (114 loc) · 4.43 KB
/
update_wallet.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
<?php include('header.php');
if(!isset($_SESSION['user']))
{
header('location:login.php');
}?>
<link rel="stylesheet" href="validation/dist/css/bootstrapValidator.css"/>
<script type="text/javascript" src="validation/dist/js/bootstrapValidator.js"></script>
<!-- =============================================== -->
<?php
include('form.php');
$frm=new formBuilder;
?>
</div>
<ul class="group" id="example-one">
<li><a href="update_wallet1.php">Saved Cards</a></li>
<li><a href="update_wallet.php">Credit Card</a></li>
</ul>
<table class="table table-bordered">
<h3>Wallet</h3>
<tbody>
<tr>
<td>Wallet Amount</td>
<td><?php
$qry2=mysqli_query($con,"select * from tbl_wallet ");
while($m=mysqli_fetch_array($qry2))
{
?>
<h4 class="h-text"><?php echo $m['wallet_bal']?></h4>
</td>
</tr>
</tbody>
</table>
<?php }?>
<div class="content">
<div class="wrap">
<div class="content-top">
<h3>Payment</h3>
<form action="bank3.php" method="post" id="form1">
<div class="col-md-4 col-md-offset-4" style="margin-bottom:50px">
<div class="form-group">
<label class="control-label">Name on Card</label>
<input type="text" class="form-control" name="name">
</div>
<div class="form-group">
<label class="control-label">Card Number</label>
<input type="text" class="form-control" name="number" required title="Enter 16 digit card number">
</div>
<div class="form-group">
<label class="control-label">Expiration date</label>
<input type="date" class="form-control" name="date">
</div>
<div class="form-group">
<label class="control-label">CVV</label>
<input type="text" class="form-control" name="cvv">
</div>
<div class="form-group">
<label class="control-label">Amount</label>
<input type="text" class="form-control" name="wallet_bal">
</div>
<div class="form-group">
<button class="btn btn-success" name="sbmtt">Make Payment</button>
</form>
</div>
</div>
</div>
<div class="clear"></div>
</div>
<?php include('footer.php');?>
</div>
<script>
$(document).ready(function() {
$('#form1').bootstrapValidator({
fields: {
name: {
verbose: false,
validators: {notEmpty: {
message: 'The Name is required and can\'t be empty'
},regexp: {
regexp: /^[a-zA-Z ]+$/,
message: 'The Name can only consist of alphabets'
} } },
number: {
verbose: false,
validators: {notEmpty: {
message: 'The Card Number is required and can\'t be empty'
},stringLength: {
min: 16,
max: 16,
message: 'The Card Number must 16 characters long'
},regexp: {
regexp: /^[0-9 ]+$/,
message: 'Enter a valid Card Number'
} } },
date: {
verbose: false,
validators: {notEmpty: {
message: 'The Expire Date is required and can\'t be empty'
} } },
cvv: {
verbose: false,
validators: {notEmpty: {
message: 'The cvv is required and can\'t be empty'
},stringLength: {
min: 3,
max: 3,
message: 'The cvv must 3 characters long'
},regexp: {
regexp: /^[0-9 ]+$/,
message: 'Enter a valid cvv'
} } }
}
});
});
</script>