第2课JavaScript语法2.pptVIP

  • 4
  • 0
  • 约9.71千字
  • 约 50页
  • 2018-05-04 发布于四川
  • 举报
JavaScript 语法基础 JavaScript基础 基本的流程控制语句 条件判断语句 if switch 循环语句 for(初始化;条件;增量) do…while while 条件语句 if …else语句 switch语句 if条件语句示例1 html head title祝福你/title /head body script language=JavaScript !-- var now = new Date(); var seconds = now.getSeconds(); if(seconds =10){ document.bgColor = #FF3300; document.fgColor = #FFFF00; document.write(img src=001.gif); document.write(p这是30秒之后的页面/p); } else{ document.bgColor = #6600FF; document.fgColor = #33FF00; document.write(img src=002.gif); document.write(p这是30秒之内的页面/p); } //-- /script /body /html if应用示例2-程序清单 now = new Date(); hours = now.getHo

文档评论(0)

1亿VIP精品文档

相关文档