You may need to surround the action/method in quotes.
Code:
<form action="search_news.php" method="POST">
Quote:
in my database i have a field with datetime type how to print just the time or just the date from that type |
I can't remember how the datetime type is formatted, but you're either going to have to use internal mysql functions (if there are any) or use PHP string functions to extract the portion of the datetime then display as needed.
http://dev.mysql.com/doc/mysql/en/DATETIME.html
So if the format is YYYYMMDDHHMMSS:
PHP Code:
$dt = substr($row_result["datetime_fieldname"], 0, 8);
// now $dt is "YYYYMMDD"
$tm = substr($row_result["datetime_fieldname"], 8);
// $tm is HHMMSS