File: /home/rtbrisc/toyotarecall.rtbriscoe.com/server/index.php
<?php
session_start();
require_once("connect.php");
$vin = mysqli_real_escape_string($con, $_POST['txtVin']);
if (empty($vin)) {
$_SESSION['msg'] = "<span class='text-danger'>Please enter you VIN in the space below...</span>";
header("Location: ../");
}else{
$query = mysqli_query($con, "SELECT * FROM tblvehicles WHERE VIN1 = '$vin' || VIN2 = '$vin'");
$row = mysqli_fetch_assoc($query);
if ($row) {
$_SESSION['det'] = $row;
header("Location: ../details.php");
} else {
$_SESSION['msg'] = "Either your VIN is incorrect or you are not eligible for the recall program!!!";
header("Location: ../");
}
}
?>