zoukankan      html  css  js  c++  java
  • *js获得当前时间*

    <td   width="217"   align="right">日期    
                      <script   language="JavaScript"   class="unnamed1">  
      var   enabled   =   0;   today   =   new   Date();                                                                                                                                                                                                                                                          
      var   day;   var   date;                                                                                                                                                                                                                                                          
      if(today.getDay()==0)   day   =   "星期日"                                                                                                                                                                                                                                                          
      if(today.getDay()==1)   day   =   "星期一"                                                                                                                                                                                                                                                          
      if(today.getDay()==2)   day   =   "星期二"                                                                                                                                                                                                                                                          
      if(today.getDay()==3)   day   =   "星期三"                                                                                                                                                                                                                                                          
      if(today.getDay()==4)   day   =   "星期四"                                                                                                                                                                                                                                                          
      if(today.getDay()==5)   day   =   "星期五"                                                                                                                                                                                                                                                          
      if(today.getDay()==6)   day   =   "星期六"                                                                                                                                                                                                                                                          
      date   =   (today.getYear())   +"年"     +   (today.getMonth()   +   1   )   +   "月"     +   today.getDate()   +   "日";                                                                                                                                                                                                                                                          
      document.write("<span   style=\"font-size:12px;\"   >");                                                                                                                                                                                                                                                          
      document.write(date);    
      document.write("&nbsp;");                                                                                                                                                                                                                                                        
      document.write(day);    
      document.write("</span>");                                                                                                                                                                                                                                                          
      </script>  
          </td>  
  • 相关阅读:
    Java并发容器和线程池
    CountDownLatch、CyclicBarrier
    spring data jpa
    转换时间的工具类(1)
    swagger 报错: TypeError: Failed to execute 'fetch' on 'Window': Request with GET/HEAD method cannot h
    自动生成entry-mapper-service-controller
    Hutool工具包导出Excel文件异常 You need to add dependency of poi-ooxml to your project
    Java获取24小时制的时间方法
    查询全国城市行政区
    Java对象与Json字符串之间的转化
  • 原文地址:https://www.cnblogs.com/dwjaissk/p/562703.html
Copyright © 2011-2022 走看看