open() or die($db->error()); $pageid = $_REQUEST['pid']; $pagename = $_REQUEST['pname']; getProjectDetail($pageid,$pagename,$db); getProjectContentDetail($pageid,$pagename,$db); getPages($pageid,$pagename,$db); if($pagename) { $pagenameVal = str_replace("-"," ", $pagename); } if(isset($_POST['Register'])){ $NAME= $_POST['txt_name']; $EMAIL= $_POST['txt_email']; $PHONE= $_POST['txt_phone']; $CITY= $_POST['txt_city']; $MSG= $_POST['txt_comments']; $PID= $_POST['project_id']; $PTITLE= $_POST['project_title']; $TYPE="enquiry-project"; $IP = getenv("REMOTE_ADDR"); $CREATED_AT = strtotime("now"); //receiver $to = "info@builderflight.com"; // subject of the mail $subject = "$NAME is intrested in $PTITLE"; // from mail $from1 = "From:$EMAIL \r\n"; // setting message which will sent to the e-mail //------------------------------------------------ $message = "Enquiry on builderflight.com via Project Page \n IP - Address: $IP \n Name : $NAME \n Email Id : $EMAIL \n Project Id : $PID \n Project Name : $PTITLE \n Contact : $PHONE \n City : $CITY \n Comments : $MSG \n"; // mail script send through the server mail($to,$subject,$message,$from1); // Echo " Thanks we will get back soon"; $message1="Thanks $NAME, For your your interest in $PTITLE. You will get a call back from us within next 24 hours.\n\n Thanks \n BuilderFlight Team \r Contact : +91 1204247021 E-Mail : info@builderflight.com F-4, D-242,Sector-63, Noida"; $subject1 = "Thanks for contacting us Mr/Mrs $NAME"; $from2="From:$to \r\n"; mail($from1,$subject1,$message1,$from2); addQuerytoDataBase($NAME,$EMAIL,$PHONE,$CITY,$MSG,$TYPE,$IP,$PID,$PTITLE,$CREATED_AT,$db); } if($_SESSION['SESS_v_siteuser']) { $TOPBAR = ReadTemplate("$TEMPLATE_DIR/common/topbar_login.html"); } else { $TOPBAR = ReadTemplate("$TEMPLATE_DIR/common/topbar_project.html"); } $PAGE_CONTENTS = ReadTemplate("$TEMPLATE_DIR/project.html"); //$LEFT_CONTENTS = ReadTemplate("$TEMPLATE_DIR/common/project_leftbar.html"); //$BOTTOMBAR = ReadTemplate("$TEMPLATE_DIR/common/project_bottombar.html"); $SUB_TEMPLATE = ReadTemplate("$TEMPLATE_DIR/common/sub_template_project.html"); $TEMPLATE = ReadTemplate("$TEMPLATE_DIR/common/project_template.html"); ReplaceContent(Array("TOPBAR", "BOTTOMBAR","LEFT_CONTENTS", "PAGE_CONTENTS", "SUB_TEMPLATE", "TEMPLATE")); print $TEMPLATE; flush(); function getPages($pageid,$pagename,$db) { global $NEWS_HEADLINES, $MAP_VROOT_PATH, $IMG_DIR, $DOCUMENT_ROOT, $NEWS_PIC_DIR, $GRID1, $GRID2,$GRIDLIST,$GRIDLIST1, $TEMPLATE_DIR; global $v_location,$v_newspaper,$d_newsDate,$developer_title,$profle,$pagename,$i_newsID,$LIST; /*if($pagename){ $v_pgTitleArr = explode("_",$pagename); if(count($v_pgTitleArr) >1) { $pagenameStr = implode(" ",$v_pgTitleArr); $pagenameStr = strtoupper($pagenameStr); } else { $pagenameStr = strtoupper($pagename); } } */ $pidDecode = base64_decode($pageid); if($pidDecode) { $pidDecodeArr = explode("_",$pidDecode); $pidVal = $pidDecodeArr[1]; } $query2="select * from tbl_developers where developer_id ='$pidVal'"; $db->query($query2); $total = $db->num_rows(); if($total >0){ $row = $db->fetch_array(); $developer_title = ucfirst($row[developer_title]); $profle = $row[profle]; } else { $pagename = "Error"; $PAGE = "No Page Found!"; } } function getProjectDetail($pageid,$pagename,$db) { global $PROJECT_LOGO,$display_location,$TOP_LEFT_VAL,$display_price,$acc,$pidVal,$project_title,$AMENTIES,$AMENTIES1, $LAT, $LONG; $pidDecode = base64_decode($pageid); if($pidDecode) { $pidDecodeArr = explode("_",$pidDecode); $pidVal = $pidDecodeArr[1]; } $query2="select * from tbl_project_dtls where project_id ='$pidVal'"; $db->query($query2); $total = $db->num_rows(); if($total >0){ $TOP_LEFT_VAL = ""; $row = $db->fetch_array(); $project_title = ucfirst($row[project_title]); $project_id = $row[project_id]; $project_type = $row[project_type]; $project_city = $row[project_city]; $project_location = $row[project_location]; $project_image = $row[project_image]; $project_logo = $row[project_logo]; $power_backup = $row[power_backup]; $ifms = $row[ifms]; $tower = $row[tower]; $corner_unit = $row[corner_unit]; $display_location = $row[display_location]; $LAT = ($row['latitude'] != '')?$row['latitude']:''; $LONG = ($row['longitude'] != '')?$row['longitude']:''; $display_price = $row['display_price']; $acc = getAccomodation($row); if(isset($row['amenities']) && $row['amenities'] != '') { $amenitiesData = explode(',', $row['amenities']); $AMENTIES = '