<?php
session_start();

if(isset($_POST['gender']) && isset($_POST['ward']) &&  $_POST['rcity']) &&  isset($_POST['dob']) && isset($_POST['phoneno']) && isset($_POST['ownid']) && isset($_POST['hname']) && isset($_POST['email']) && isset($_POST['pobox']) && isset($_POST['vilage']) && isset($_POST['district'])){

 
$ward=$_POST['gender']; $ward=$_POST['ward']; $rcity=$_POST['rcity']; $dob=$_POST['dob']; $own=$_POST['ownid'];   $hn=$_POST['hname'];  $po=$_POST['pobox'];

$em=$_POST['email'];  $dist =$_POST['district']; $vil=$_POST['vilage']; $phn =$_POST['phoneno'];

$reg=Date("Ymdhis");
 $tras=Date("Y-m-d");
include("buda_connect.php");

mysql_query("insert into hotel(hotel_id,owner_id, hname,ltown_city,lstreet_vil,paddress,email,reg_date) values ('$reg','$own','$hn','$dist','$vil','$po','$em','$tras')") or die("Error :".mysql_error());


mysql_query("insert into phone_number(hotel_id,phno) values('$reg','$phn')") or die("Error :".mysql_error());

 

 

}
else{
echo "No value posted";

}
?>