VBScript 日期函式



Day 函式會返回一個介於 1 到 31 之間表示特定日期的日期的數字。

語法

Day(date) 

示例

<!DOCTYPE html>
<html>
   <body>
      <script language = "vbscript" type = "text/vbscript">
         document.write(Day("2013-06-30"))
       
      </script>
   </body>
</html>

當你把程式碼儲存為 .html 並用 Internet Explorer 執行,然後上述指令碼將會產生以下結果 −

30
vbscript_date.htm
廣告
© . All rights reserved.