s: Set and s: date are used to judge the date in JSP

Time:2021-4-12

Copy codeThe code is as follows:
<s:set name=”todayDay” value=”new java.sql.Date(new java.util.Date().getTime()).toString()”/>
<s:date name=”Schd_Dpt_Dt” format=”yyyy-MM-dd” var=”Schd_Dpt_Date”/>

<s:if test=”#todayDay==#Schd_Dpt_Date”>
  <td>
    <s:date name=”Schd_Dpt_Dt” format=”HH:mm” />
  </td>
</s:if>
<s:else>
  <td>
    <s:date name=”Schd_ Dpt_ DT “format =” DD day HH: mm “/ >
  </td>
</s:else>

Recommended Today

Review of SQL Sever basic command

catalogue preface Installation of virtual machine Commands and operations Basic command syntax Case sensitive SQL keyword and function name Column and Index Names alias Too long to see? Space Database connection Connection of SSMS Connection of command line Database operation establish delete constraint integrity constraint Common constraints NOT NULL UNIQUE PRIMARY KEY FOREIGN KEY DEFAULT […]