I have a field in my news table that is date_entered
When the news item is entered into the database, it inserts the date into the database with NOW();
$query = "INSERT INTO blog_entries (blog_id, title, entry, date_entered) VALUES (0,'{$_POST['title']}', '{$_POST['entry']}', NOW())";
and when I pull the news/blog entries out of the database it is not showing the date entered:
if ($r = mysql_query ($query)) // Run the query.
{
// Retrieve and print every record.
while ($row = mysql_fetch_array ($r))
{
echo "<p><h3>{$row['title']}</h3>{row['date_entered']}<br />
{$row['entry']}<br />
</p><hr />\n";
}
}
else
{ // Query didn't run.
die ('<p>Could create the table because: <b>' . mysql_error() . "</b>. The query was $query.</p>");
} // End of query IF.
I know that this is a simple conversion, but I am having a simple brain F***T
any help would be apprecaited!!! the date format is 2006-08-29 08:29:14
TIA,
Mike