JSP condition練習
jsp_condition_if
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
</head>
<body>
<script type="text/javascript">
var myDate=new Date()
var time=myDate.getHours()
if (time<12) {
document.write("<b>早上好</b>")
}
</script>
</html>
jsp_condition_if_els
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
</head>
<body>
<script type="text/javascript">
var d=new Date()
var time =d.getHours ()
if (time>20){
document.write("<b>晚安</b>")
}
else if (time >8 &&time <10){
document.write("<b>早安</b>")
}
else{
document.write("<b>你好!</b>")
}
</script>
</body>
</html>
相關文章
- SSM的查詢簡單練習+JSPSSMJS
- 實戰練習之Jsp自定義標籤JS
- python學習-conditionPython
- markdown 使用練習練習
- JavaEE學習之走進JSPJavaJS
- 新手練習:Python練習題目Python
- condition的作用
- java基礎學習:JavaWeb之JSPJavaWebJS
- MYSQL練習1: DQL查詢練習MySql
- Java併發——ConditionJava
- 06 ReentrantLock之ConditionReentrantLock
- Condition實現原理
- python練習Python
- MySQL練習MySql
- ddl練習
- latex練習
- MySQ練習
- openGauss練習
- jsp標籤jsp:useBean用法JSBean
- jsp基礎-初識jspJS
- javaweb練手專案jsp+servlet簡易購物車系統JavaWebJSServlet
- JSPJS
- 肥桃的Java學習記錄22:JSPJavaJS
- U7-11課綜合練習+12課階段測評練習——複習練習題目
- 併發-10-Condition
- Condition條件變數變數
- 鎖——Lock、Condition、ReadWriteLock、LockSupport
- Lock介面之Condition介面
- python 練習0000Python
- C++練習C++
- shell練習題
- 【練習】canvas——flappyBirdCanvasAPP
- Python 練習題Python
- 隨堂練習
- SQL練習題SQL
- mysql練習題MySql
- TypeScript 練習題TypeScript
- JS原生練習JS