EL expression
Objects in the access scope (request)
Syntax $ {EL expression}
Common Operators
. Used to access the property user. name
[] Used to access the object property user ["name"]
Used to access data or set users [1]
Used to access objects containing special characters $ {requestScope. ["user. name"]}
Common Operators
() Changing the computing priority
+-/* Arithmetic Operators
= ,! =, <,> Relational operators
&, | Logical operators
? : Conditional operator $ {? B: c}
Empty is used to check whether variables are saved.
At, no equals to null
Values in each function
Request $ {requestScope. news}
Session $ {sessionScope. news}
Applocation $ {applocationScope. news}
Page $ {pagination. news}
Jstl jsp standard tag library can replace java code to a certain extent
Procedure
1. Add jslt. jar and standard. jar to the project.
2. Add commands on the JSP page
<% @ Taglib uri = "http://java.sun.com/jsp/jstl/core" prefix = "c" %>
Tag Library
Resource Identifier prefix
Core label library http://java.sun.com/jsp/jstl/core c
International tag library http://java.sun.com/jsp/jstl/fmt fmt
XML library http://java.sun.com/jsp/jstl/xml x
Database tag library http://java.sun.com/jsp/jstl/ SQL SQL
Function tag library http://java.sun.com/jsp/jstl/functions fn
Common labels
Value = "" displayed value
EscapeXml = "true" escape?
Default = "" default Value
>
Var = "" variable name
Value = "" variable value
Scope = "" scope
>
Var = "" variable name
Scope = "" scope
>
Var = "var" set element name, which calls the object of this loop with $ {var}
Items = "" loop object
VarStatus = ""> cyclic status
Test = "" judgment Condition
Var = "" stores judgment results
Scope = "" var scope
>
Value = "" url to be constructed
>
Name = "" additional parameter name
Value = "" value of the additional parameter
>
Uri = "" reference page url
>
Vlaue = "" time object
Pattern = "" Time Format
>