Question: What is an Expression tag in JSP?

By: Guru Singh Printer Friendly Format    

Question: What is an Expression tag in JSP?

Answer: An expression tag contains a scripting language expression that is evaluated, converted to a String, and inserted where the expression appears in the JSP file. Because the value of an expression is converted to a String, you can use an expression within text in a JSP file. 

Like
<%= someexpression %>

<%= (new java.util.Date()).toLocaleString() %>

You cannot use a semicolon to end an expression

 

 

 

 



Most Viewed Articles (in Interview )

Question: What is the directory structure of a web application?

Types of Interviews

Interview Question: What is the difference between JavaBean and EJB?

Interview Question: What is local interface. How values will be passed?

Interview Question: What is Message Driven Bean?

Interview Question: What is deployment descriptor?

Interview Question: How many EJB Objects are created for a Bean?

Interview Question: What is re-entrant. Is session beans reentrant. Is entity beans reentrant?

Interview Question: Is Decorator an EJB design pattern?

Interview Question: What is the difference between sessioncontext and entitycontext?

Interview Question: What is the difference between ejbCreate() and ejbPostCreate?

Interview Question: What are the optional clauses in EJB QL?

Interview Question: What is Local client view in EJB?

Interview Question: If the framework doesn't do what I want, can I request that a feature be added?

Interview Question: Does Struts include its own unit tests?

Latest Articles (in Interview)

Comment on this tutorial