hi i am having problems with inserting data from my form no error are outputted although the records are not being inserted my code is
html code
<html>
<head>
<title>Saj_Sales_Cars</title>
</head>
<body>
<form action='Saj_Sales_Cars_Admin.php' method='post'>
<table border="0">
<tr>
<td>Registration Number:</td>
<td> <input type='text' name='Registration_Number'></td>
<td>Road Tax:</td>
<td> <input type='text' name='Road_Tax'></td>
<td>Type of transmission: </td>
<td>
<select id ="Type_of_Transmission" name = "Type_of_Transmission">
<option value="Automatic">Automatic</option>
<option value="Manual">Manual</option>
</select>
</td>
<td>Sunroof:</td>
<td>
<select id ="Sunroof" name = "Sunroof">
<option value="Yes">Yes</option>
<option value="No">No</option>
</select>
</td>
<td>Other Extras:</td>
<td> <input type='text' name='Other_Extras'></td>
</tr>
<tr>
<td>Year:</td>
<td>
<select id ="Year" name = "Year">
<option value="1998">1998</option>
<option value="1999">1999</option>
<option value="2000">2000</option>
<option value="2001">2001</option>
<option value="2002">2002</option>
<option value="2003">2003</option>
<option value="2004">2004</option>
<option value="2005">2005</option>
<option value="2006">2006</option>
<option value="2007">2007</option>
<option value="2008">2008</option>
<option value="2009">2009</option>
</select>
</td>
<td>Service History:</td>
<td>
<select id ="Service_History" name = "Service_History">
<option value="FSH">FSH</option>
<option value="SH">SH</option>
<option value="No">No</option>
</select>
</td>
<td>Fuel Type:</td>
<td>
<select id ="Fuel_Type" name = "Fuel_Type">
<option value="Petrol">Petrol</option>
<option value="Diesel">Diesel</option>
</select>
</td>
<td>CD Player:</td>
<td>
<select id ="CD_Player" name = "CD_Player">
<option value="Yes">Yes</option>
<option value="No">No</option>
</select>
</td>
<td>Buying Price:</td>
<td> <input type='text' name='Buying_Price'></td>
</tr>
<tr>
<td>
Make:</td>
<td>
<select id ="Make" name = "Make">
<option value="Audi">Audi</option>
<option value="BMW">BMW</option>
<option value="Citroen">Citreon</option>
<option value="Fiat">Fiat</option>
<option value="Ford">Ford</option>
<option value="Honda">Honda</option>
<option value="Lexus">Lexus</option>
<option value="Mercedes-Benz">Mercedes_Benz</option>
<option value="MG">MG</option>
<option value="Mini">Mini</option>
<option value="Mitsubishi">Mitsubishi</option>
<option value="Nissan">Nissan</option>
<option value="Peugeot">Peugeot</option>
<option value="Proton">Proton</option>
<option value="Renualt">Rentualt</option>
<option value="Rover">Rover</option>
<option value="Saab">Saab</option>
<option value="Seat">Seat</option>
<option value="Skoda">Skoda</option>
<option value="Toyota">Toyota</option>
<option value="Vauxhall">Vauxhall</option>
<option value="Volkswagen">Volkswagen</option>
<option value="Volvo">Volvo</option>
</select>
</td>
<td>
Colour:</td>
<td>
<select id ="Colour" name = "Colour">
<option value="Beige">Beige</option>
<option value="Black">Black</option>
<option value="Blue">Blue</option>
<option value="Bronze">Bronze</option>
<option value="Burgundy">Burgundy</option>
<option value="Gold">Gold</option>
<option value="Green">Green</option>
<option value="Grey">Grey</option>
<option value="Indigo">Indigo</option>
<option value="Magenta">Magenta</option>
<option value="Maroon">Maroon</option>
<option value="Navy">Navy</option>
<option value="Orange">Orange</option>
<option value="Pink">Pink</option>
<option value="Purple">Purple</option>
<option value="Red">Red</option>
<option value="Silver">Silver</option>
<option value="Turquoise">Turquoise</option>
<option value="White">White</option>
<option value="Yellow">Yellow</option>
</select>
</td>
<td>PAS:</td>
<td>
<select id ="PAS" name = "PAS">
<option value="Yes">Yes</option>
<option value="No">No</option>
</select>
</td>
<td>Electric Windows:</td>
<td>
<select id ="Electric_Windows" name = "Electric_Windows">
<option value="Yes">Yes</option>
<option value="No">No</option>
</select>
</td>
<td>Car Sale Invoice Number:</td>
<td> <input type='text' name='Car_Sale_Invoice_Number'></td>
</tr>
<tr>
<td>
Model: </td>
<td>
<select id ="Model" name = "Model">
<option value="100">100</option>
<option value="80">80</option>
<option value="90">90</option>
<option value="A2">A2</option>
<option value="A3">A3</option>
<option value="A4">A4</option>
<option value="A5">A5</option>
<option value="A6">A6</option>
<option value="A8">A8</option>
<option value="Q5">Q5</option>
<option value="Q7">Q7</option>
<option value="R8">R8</option>
<option value="RS2">RS2</option>
<option value="RS4">RS4</option>
<option value="RS6">RS6</option>
<option value="S2">S2</option>
<option value="S3">S3</option>
<option value="S4">S4</option>
<option value="S5">S5</option>
<option value="S6">S6</option>
<option value="S8">S8</option>
<option value="TT">TT</option>
<option value="1 Series">1 Series</option>
<option value="3 Series">3 Series</option>
<option value="5 Series">5 Series</option>
<option value="6 Series">6 Series</option>
<option value="7 Series">7 Series</option>
<option value="8 Series">8 Series</option>
<option value="M3">M3</option>
<option value="M5">M5</option>
<option value="M6">M6</option>
<option value="X3">X3</option>
<option value="X5">X5</option>
<option value="X6">X6</option>
<option value="Z1">Z1</option>
<option value="Z3">Z3</option>
<option value="Z4">Z4</option>
<option value="Saxo">Saxo</option>
<option value="Brava">Brava</option>
<option value="Bravo">Bravo</option>
<option value="Punto">Punto</option>
<option value="Fiesta">Fiesta</option>
<option value="Focus">Focus</option>
<option value="Accord">Accord</option>
<option value="Civic">Civic</option>
<option value="GS">GS</option>
<option value="IS">IS</option>
<option value="A Class">A Class</option>
<option value="B Class">B Class</option>
<option value="C Class">C Class</option>
<option value="E Class">E Class</option>
<option value="S Class">S Class</option>
<option value="MGF">MGF</option>
<option value="TF">TF</option>
<option value="ZR">ZR</option>
<option value="ZT">ZT</option>
<option value="Cooper">Cooper</option>
<option value="One">One</option>
<option value="Carisma">Carisma</option>
<option value="Colt">Colt</option>
<option value="Glant">Glant</option>
<option value="Almera">Almera</option>
<option value="Micra">Micra</option>
<option value="Primera">Primera</option>
<option value="106">106</option>
<option value="107">107</option>
<option value="205">205</option>
<option value="206">206</option>
<option value="207">207</option>
<option value="306">306</option>
<option value="307">307</option>
<option value="405">405</option>
<option value="Compact">Compact</option>
<option value="Persona">Persona</option>
<option value="Satria">Satria</option>
<option value="Wira">Wira</option>
<option value="Clio">Clio</option>
<option value="Laguna">Laguna</option>
<option value="Megane">Megane</option>
<option value="100">100</option>
<option value="200">200</option>
<option value="25">25</option>
<option value="400">400</option>
<option value="45">45</option>
<option value="600">600</option>
<option value="75">75</option>
<option value="800">800</option>
<option value="9-3">9-3</option>
<option value="9-5">9-5</option>
<option value="90">90</option>
<option value="900">900</option>
<option value="96">96</option>
<option value="99">99</option>
<option value="Ibiza">Ibiza</option>
<option value="Leon">Leon</option>
<option value="Fabia">Fabia</option>
<option value="Octavia">Octavia</option>
<option value="Superb">Superb</option>
<option value="Avensis">Avensis</option>
<option value="Camry">Camry</option>
<option value="Carina">Carina</option>
<option value="Celica">Celica</option>
<option value="Corolla">Corolla</option>
<option value="Starlet">Starlet</option>
<option value="Yaris">Yaris</option>
<option value="Astra">Astra</option>
<option value="Corsa">Corsa</option>
<option value="Vectra">Vectra</option>
<option value="Bora">Bora</option>
<option value="Golf">Golf</option>
<option value="Passat">Passat</option>
<option value="240">240</option>
<option value="340">340</option>
<option value="440">440</option>
<option value="460">460</option>
<option value="480">480</option>
<option value="740">740</option>
<option value="760">760</option>
<option value="850">850</option>
</select>
</td>
<td>
No of Doors: </td>
<td>
<select id ="No_of_Doors" name = "No_of_Doors">
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
</select>
</td>
<td>
No of Owners: </td>
<td>
<select id ="No_of_Owners" name = "No_of_Owners">
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
</select>
</td>
<td>Central Locking:</td>
<td>
<select id ="Central_Locking" name = "Central_Locking">
<option value="Yes">Yes</option>
<option value="No">No</option>
</select>
</td>
<td>Date of Purchase:</td>
<td> <input type='text' name='Date_of_Purchase'></td>
</tr>
<tr>
<td>Mileage:</td>
<td> <input type='text' name='Mileage'>
</td>
<td>
Engine Size:</td>
<td>
<select id ="Engine_Size" name = "Engine_Size">
<option value="1.0">1.0</option>
<option value="1.1">1.1</option>
<option value="1.2">1.2</option>
<option value="1.3">1.3</option>
<option value="1.4">1.4</option>
<option value="1.5">1.5</option>
<option value="1.6">1.6</option>
<option value="1.7">1.7</option>
<option value="1.8">1.8</option>
<option value="1.9">1.9</option>
<option value="2.0">2.0</option>
<option value="2.1">2.1</option>
<option value="2.2">2.2</option>
<option value="2.3">2.3</option>
<option value="2.4">2.4</option>
<option value="2.5">2.5</option>
<option value="2.6">2.6</option>
<option value="2.7">2.7</option>
<option value="2.8">2.8</option>
<option value="2.9">2.9</option>
<option value="3.0">3.0</option>
<option value="3.1">3.1</option>
<option value="3.2">3.2</option>
<option value="3.3">3.3</option>
<option value="3.4">3.4</option>
<option value="3.5">3.5</option>
<option value="3.6">3.6</option>
<option value="3.7">3.7</option>
<option value="3.8">3.8</option>
<option value="3.9">3.9</option>
<option value="4.0">4.0</option>
<option value="4.1">4.1</option>
<option value="4.2">4.2</option>
<option value="4.3">4.3</option>
<option value="4.4">4.4</option>
<option value="4.5">4.5</option>
<option value="4.6">4.6</option>
<option value="4.7">4.7</option>
<option value="4.8">4.8</option>
<option value="4.9">4.9</option>
<option value="5.0">5.0</option>
<option value="5.1">5.1</option>
<option value="5.2">5.2</option>
<option value="5.3">5.3</option>
<option value="5.4">5.4</option>
<option value="5.5">5.5</option>
<option value="5.6">5.6</option>
<option value="5.7">5.7</option>
<option value="5.8">5.8</option>
<option value="5.9">5.9</option>
</select>
</td>
<td>
Condition:</td>
<td>
<select id ="Condition" name = "Condition">
<option value="Superb">Superb</option>
<option value="Good">Good</option>
<option value="Average">Average</option>
<option value="Poor">Poor</option>
<option value="Damaged">Damaged</option>
</select>
</td>
<td>Alarm:</td>
<td>
<select id ="Alarm" name = "Alarm">
<option value="Yes">Yes</option>
<option value="No">No</option>
</select>
</td>
</tr>
<tr>
<td>
MOT:</td>
<td> <input type='text' name='MOT'>
</td>
<td>
Type of Car:</td>
<td>
<select id ="Type_of_Car" name = "Type_of_Car">
<option value="Hatchback">Hatchback</option>
<option value="Saloon">Saloon</option>
<option value="Estate">Estate</option>
<option value="Convertible">Convertible</option>
<option value="Coupe">Coupe</option>
<option value="4x4">4x4</option>
</select>
</td>
<td>Alloy Wheels:</td>
<td>
<select id ="Alloy_Wheels" name = "Alloy_Wheels">
<option value="Yes">Yes</option>
<option value="No">No</option>
</select>
</td>
<td>Airbags:</td>
<td>
<select id ="Airbags" name = "Airbags">
<option value="Yes">Yes</option>
<option value="No">No</option>
</select>
</td>
</tr>
</table>
<br><br>
<input type='submit' value='Insert'>
</form>
</body>
</html>
and the php code is
<?php
$Registration_Number = $_POST['Registration_Number'];
$Year = $_POST['Year'];
$Make = $_POST['Make'];
$Model = $_POST['Model'];
$Mileage = $_POST['Mileage'];
$MOT = $_POST['MOT'];
$Road_Tax = $_POST['Road_Tax'];
$Service_History = $_POST['Service_History'];
$Colour = $_POST['Colour'];
$No_of_Doors = $_POST['No_of_Doors'];
$Engine_Size = $_POST['Engine_Size'];
$Type_of_Car = $_POST['Type_of_Car'];
$Type_of_Transmission = $_POST['Type_of_Transmission'];
$Fuel_Type = $_POST['Fuel_Type'];
$PAS = $_POST['PAS'];
$No_of_Owners = $_POST['No_of_Owners'];
$Condition_of_Car = $_POST['Condition_of_Car'];
$Alloy_Wheels = $_POST['Alloy_Wheels'];
$Sunroof = $_POST['Sunroof'];
$CD_Player = $_POST['CD_Player'];
$Electric_Windows = $_POST['Electric_Windows'];
$Central_Locking = $_POST['Central_Locking'];
$Alarm = $_POST['Alarm'];
$Airbags = $_POST['Airbags'];
$Other_Extras = $_POST['Other_Extras'];
$Buying_Price = $_POST['Buying_Price'];
$Car_Sale_Inv_Invoice_Number = $_POST['Car_Sale_Invoice_Number'];
$Date_of_Purchase = $_POST['Date_of_Purchase'];
@mysql_connect("localhost","root",""
![winking smiley winking smiley](./mods/smileys/images/smilie3.gif)
or die("Error: unable to connect or incorrect user"
![winking smiley winking smiley](./mods/smileys/images/smilie3.gif)
;
@mysql_select_db("saj_car"
![winking smiley winking smiley](./mods/smileys/images/smilie3.gif)
or die("Error: unable to connect to Database"
![winking smiley winking smiley](./mods/smileys/images/smilie3.gif)
;
$Insert1 = "INSERT INTO saj_sales_cars (Registration_Number, Year, Make, Model, Mileage, MOT, Road_Tax, Service_History, Colour, No_of_Doors, Engine_Size, Type_of_Car, Type_of_Transmission, Fuel_Type, PAS, No_of_Owners, Condition_of_Car, Alloy_Wheels, Sunroof, CD_Player, Electric_Windows, Central_Locking, Alarm, Airbags, Other_Extras)
VALUES ('".$Registration_Number."','".$Year."','".$Make."','".$Model."','".$Mileage."','".$MOT."','".$Road_Tax."','".$Service_History."','".$Colour."','".$No_of_Doors."','".$Engine_Size."','".$Type_of_Car."','".$Type_of_Transmission."','".$Fuel_Type."','".$PAS."','".$No_of_Owners."','".$Condition_of_Car."','".$Alloy_Wheels."','".$Sunroof."','".$CD_Player."','".$Electric_Windows."','".$Central_Locking."','".$Alarm."','".$Airbags."','".$Other_Extras."') ";
$Insert2 = "INSERT INTO saj_sales_invoices (Car_Sale_Invoice_Number, Registration_Number, Buying_Price, Date_Of_Purchase)
VALUES ('".$Car_Sale_Invoice_Number."','".$Registration_Number."','".$Buying_Price."','".$Date_of_Purchase."') ";
echo "Your searched cars have ended. Please <a href='private_page.php?username=$Username&password=$Password'>continue</a>.";
?>
thanks