javascript日期constructor屬性返回一個引用到創建實例的prototype數組函數。
語法
date.constructor
下麵是參數的詳細資訊:
-
NA
返回值:
返回創建此對象的實例的函數。
例子:
<html>
<head>
<title>JavaScript Date constructor Property</title>
</head>
<body>
<script type="text/javascript">
var dt = new Date();
document.write("dt.constructor is : " + dt.constructor);
</script>
</body>
</html>
這將產生以下結果:
dt.constructor is: function Date() { [native code] }
上一篇:
JavaScript Date對象
下一篇:
Javascript Date()函數
