-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathipn.php
65 lines (51 loc) · 1.85 KB
/
ipn.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
<?php
require_once 'shurjoPay.php';
$spObject = new shurjoPay();
$response_data = (object) array('Status'=>'No data found');
if($_REQUEST['order_id'])
{
$order_id = trim($_REQUEST['order_id']);
$response_data = json_decode($spObject->decrypt_and_validate($order_id));
}
try {
$logmsg = "\n".date("Y.n.j H:i:s")."#".$response_data;
file_put_contents(date("Y.n.j").'.log',$logmsg,FILE_APPEND);
} catch(Exception $e) {
file_put_contents(date("Y.n.j").'.log',$e->getMessage(),FILE_APPEND);
}
?>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="bootstrap.min.css" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<div class="container">
<div class="row">
<div class="col-12 col-sm-12 col-md-12 col-lg-12 col-xl-12">
<div class="img">
<img src="shurjopay-logo.png" alt="" class="center">
<hr>
</div>
<table id="regForm" class="table table-hover">
<?php
if(is_array($response_data)):
$response_data = array_shift($response_data);
foreach($response_data as $key => $val):
?>
<tr>
<td class="table-info"><?php echo $key?></td>
<td><?php print_r ($val);?></td>
</tr>
<?php
endforeach;
endif;
?>
<tr><td colspan="2"><a href="index.php"><b>Back</b></td></tr>
</table>
</div>
</div>
</div>
</body>
</html>