forked from razorpay/razorpay-php-testapp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
executable file
·37 lines (35 loc) · 1.15 KB
/
index.html
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
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="utf-8">
<link rel="stylesheet" href="http://yegor256.github.io/tacit/tacit.min.css"/>
</head>
<body>
<form id="checkout-selection" method="POST">
<input type="radio" name="checkout" value="automatic">Automatic Checkout Demo<br>
<input type="radio" name="checkout" value="orders">Manual Checkout Demo<br>
<input type="submit" value="Submit">
</form>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<script>
jQuery(document).ready(function($)
{
var form = $('#checkout-selection');
var radio = $('input[name="checkout"]');
var choice = '';
radio.change(function(e)
{
choice = this.value;
if (choice === 'orders')
{
form.attr('action', 'pay.php?checkout=manual');
}
else
{
form.attr('action', 'pay.php?checkout=automatic');
}
});
});
</script>
</body>
</html>