私はこの方法でmysqlデータベースに日付を入れました2012-08-02 02:20:05
。さて、smartyを使ってマイページに印刷する方法。
mycode : (注: send_date は行の名前です)
$sql = "SELECT m.*, s.photo, s.gender
FROM mail AS m, signup AS s
WHERE m.receiver = '" .mysql_real_escape_string($username). "'
AND m.sender = s.username AND inbox = '1' AND status = '1'
ORDER BY send_date DESC LIMIT " .$limit;
$rs = $conn->execute($sql);