i keep having a error with my code saying the following Error. Please try again laterColumn count doesn't match value count at row 1
could someone help me solve this
<?php include 'header.php'; include 'mysql.php'; echo '<h3>Create Catergory</h3>'; if($_SERVER['REQUEST_METHOD'] != 'POST') { //the form hasn't been posted yet, display it echo '<form method="post" action=""> Catergory Name: <input type="text" name="name" /></p> Catergory Description: <input type="textarea" name="description"></p> <input type="submit" value="Add Catergory" /> </form>'; } else { //the form has been posted, so save it $sql = "INSERT INTO catagories(name, description) VALUES('" . mysql_real_escape_string($_POST['name']) . "', '" . mysql_real_escape_string($_POST['description']) . "', NOW(), 0)"; $result = mysql_query($sql); if(!$result) { echo 'Error. Please try again later';//. mysql_error(); exit(); } else { echo 'New category successfully added.'; exit(); } } include 'footer.php'; ?>