forked from rajula96reddy/PalWalletWebApp
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun.php
More file actions
21 lines (21 loc) · 650 Bytes
/
Copy pathrun.php
File metadata and controls
21 lines (21 loc) · 650 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<?php
if($_SERVER["REQUEST_METHOD"] == "POST")
{
$amount = $_POST['amount'];
$name = $_POST['name'];
$reason = $_POST['reason'];
$servername = "localhost";
$username = "root";
$password = "smitpatel1996";
$conn = mysqli_connect($servername, $username, $password);
if (!$conn) {
die("Connection failed: " . mysqli_connect_error());
}
mysqli_select_db($conn,"finaldb");
$bool = "INSERT INTO firsttable VALUES ('L','{$_SERVER['REMOTE_ADDR']}','{$amount}','{$name}','{$reason}',CURDATE());";
mysqli_query($conn, $bool);
mysqli_close($conn);
header('Location: http://smitpatel1996.github.io/PalWallet/index.html#success');
die();
}
?>