Completely stumped. Getting Error as stated in question title, and no idea why. All my coloumns have text names an there is no reference as far as i know in my code to a column named "1". I have had someone modify this slightly to help me out so maybe there is an issue here i am unaware of.
(string)$insert;
if(is_array($_POST['Year'])){
foreach($_POST['Year'] as $k=>$v){
$insert .= "($_POST['Name'][$k], $_POST['Short'][$k], $_POST['Med'][$k], $_POST['Long'][$k], $_POST['VLong'][$k], $_POST['Extreme'][$k], $_POST['LJump'][$k], $_POST['HJump'][$k], $_POST['Shotputt'][$k], $_POST['Discuss'][$k], $_POST['Javelin'][$k], $_POST['Date'][$k], $_POST['Year'][$k]),";
}
$insert = substr_replace($insert ,0,-1);
}else{
$insert .= "($_POST['Name'], $_POST['Short'], $_POST['Med'], $_POST['Long'], $_POST['VLong'], $_POST['Extreme'], $_POST['LJump'], $_POST['HJump'], $_POST['Shotputt'], $_POST['Discuss'], $_POST['Javelin'], $_POST['Date'], $_POST['Year'])";
}
$sql="INSERT INTO results_main
(`Name`, `Short`, `Med`, `Long`, `VLong`, `Extreme`, `LJump`, `HJump`, `Shotputt`, `Discuss`, `Javelin`, `Date`, `Year`)
VALUES
".$insert;
$result = mysql_query($sql) or die(mysql_error());
// close connection
mysql_close($conn);