Commit b979f43f authored by rama chandra's avatar rama chandra
Browse files

Updated insert

parents 5830df4e 3fb5d898
<<<<<<< HEAD
define('DB_SERVER', 'localhost');
define('DB_USERNAME', 'root');
define('DB_PASSWORD', '');
......@@ -16,14 +17,38 @@ if (mysqli_connect_error()) {
$rpass = mysqli_real_escape_string($con,$_POST['rpass']);
$query = "insert into regiscred (uname,email,pass,rpass) values('$uname',$email','$pass','$rpass')";
$result = mysqli_query($con,$query);
$con = mysqli_connect("localhost", "root", "", "blood");
>>>>>>> 3fb5d8987572530825f3e6bda0d73c99c862f049
if($con === false){
die("ERROR: Could not connect. " . mysqli_connect_error());
$name = $_POST['name'];
$age = $_POST['age'];
$city= $_POST['city'];
$mobile = $_POST['number'];
$ld= $_POST['ago'];
$sql = "INSERT INTO bloo (uname,blood,age,mobile,city,dd) VALUES ('$name', '$blood', $age,'$mobile','$city',$ld)";
<<<<<<< HEAD
if($result == true){
echo"Thanks For Registering!!";
echo "<h1>Thank You for Being a Blood Donor..You will Receive a Message when there is a Requirement!! </h1>";
>>>>>>> 3fb5d8987572530825f3e6bda0d73c99c862f049
\ No newline at end of file
<?php include('init.php')?>
$obj = new base_class;
if($obj->Normal_Query("SELECT dd,uname,blood,id,mobile from bloo")){
echo "the donor"
echo $name;
echo "of blood group"
echo $blood;
echo "has donated his blood "
echo $dd;
echo "months ago and his mobile number is"
echo $mobile."<br>";
......@@ -54,7 +54,7 @@
<div class="form-group">
<select name="blood" class="form-control pb_height-50 reverse">
<option value="" selected>Your Blood Group</option>
<option value="" selected>Your Blood Group.</option>
<option value="A+">A+</option>
<option value="A-">A-</option>
<option value="B+">B+</option>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment