If i keep the code like exmpel 1 and leave it TIMESTAMP alone i get MYSQL error like this
MySQL Error Column count doesn't match value count at row 1
if i make the code look like exampel 2. this i dont get a error
But i get empty TIMESTAMP...
I have no ide whatsowever how to fixa this problem
exampel 1.
<?
function addpost () {
global $password,$email,$username,$post,$topicID;
$timestamp = time();
$new_password = addslashes($password); $new_email = addslashes($email);
$new_name = addslashes($username);
$new_post = addslashes(nl2br(htmlspecialchars($post)));
$insert = mysql_query("INSERT INTO newspost VALUES ('NULL','$topicID','$new_name','$new_email','$new_
password','$new_post','$timestamp')");
if (mysql_error() != "") {
showheader("MySQL Error ".mysql_error());
?>
<br><p><center><b>There was a MySQL Error -- <?php echo mysql_error() ?></b></center></p>
<?php
showfooter();
exit;
?>
exampel 2.
<?
$insert = mysql_query("INSERT INTO newspost VALUES ('NULL','$topicID','$new_name','$new_email','$new_
password','$new_post','$timestamp','NULL')");
?>