可能重複的格式:
Format date to MM/dd/yyyy in javascript的Javascript更改日期到(DD/MM/YYYY)
我如何轉換低於下列日期格式(星期一11月19日13:29 :40 2012)
成:
日/月/年
個<html>
<head>
<script type="text/javascript">
function test(){
var d = Date()
alert(d)
}
</script>
</head>
<body>
<input onclick="test()" type="button" value="test" name="test">
</body>
</html>
你有什麼試過的?它看起來並不像這段代碼試圖對日期進行任何串處理。 –