<?php

extract($_POST);
$to = 'info@chevy-gmc.net';

// subject
$subject = 'Inquiry Chevy Cebu';
// message
$message = '
<html>
<head>
  <title>Inquiry Chevy Cebu</title>
</head>
<body>
  <p>Inquiry Detail Information</p>
  <table>
    <tr><td>First name:</td><td>'.$fname.'</td></tr>
    <tr><td>Middle name:</td><td>'.$mname.'</td></tr>
    <tr><td>Last name:</td><td>'.$lname.'</td></tr>
    <tr><td>E-mail address:</td><td>'.$email.'</td></tr>
    <tr><td>Landline #:</td><td>'.$landline.'</td></tr>
    <tr><td>Cellphone #:</td><td>'.$cel.'</td></tr>
    <tr><td>Vehicle model:</td><td>'.$vmodel.'</td></tr>
    <tr><td>Message:</td><td>'.$msg.'</td></tr>
  </table>
</body>
</html>
';

$headers  = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
$headers .= 'From: '.$fname.' '.$lname.' <'.$email.'>';

if(mail($to, $subject, $message, $headers)):
	echo "success";
endif;


?>