在我的數據庫中有一個日期,如2013/11/12
,它必須轉換爲12th November 2013
。這裏有我的代碼:PHP轉換時間格式
$a=mysqli_connect("localhost","usern","pass","my_mk7vrlist");
//as you can see I'm getting the value of the date from a MySQL database
$res= mysqli_query($a,"SELECT * FROM 0_vrs_europe ORDER BY `vrs` DESC, `date` ASC LIMIT 0 , 150");
while($row = mysqli_fetch_array($res))
{
echo "<tr>";
echo "<td>" . $row['status'] . "</td>";
echo "<td>" . $row['date'] . "</td>";
echo "</tr>";
}
mysqli_close($res);
?>
的$row['date']
包含2013/11/12
格式的日期和它必須12th November 2013
因爲我已經說過轉換。我怎麼能這樣做?
我GOOGLE了功能date
但我不明白如何在這裏使用它。
http://fr2.php.net/manual/en/function.date.php PHP的日期功能 – Cups