What is expression in JSP?

By: Karthik Printer Friendly Format    

Answer: Expression tag is used to insert Java values directly into the output. Syntax for the Expression tag is: 
<%= expression %>
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. The following expression tag displays time on the output:
<%=new java.util.Date()%>

Ask a Question



Most Viewed Articles (in Interview )

Interview Question: What is ActionServlet?

Interview Question: What about JSTL and JavaServer Faces ?

Interview Question: Why it is called Struts?

Interview Question: Does Struts include its own unit tests?

Interview Question: Why are some of the class and element names counter-intuitive?

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

Interview Question: What is the difference between EAR, JAR and WAR file?

Why J2EE is suitable for the development distributed multi-tiered enterprise applications?

What is Deployment Descriptor?

What is J2EE Connector architecture?

What is difference between Java Bean and Enterprise Java Bean?

Explain garbage collection?

Explain the different forms of Polymorphism.

What are implicit Objects available to the JSP Page?

What are all the different scope values for the tag?

Latest Articles (in Interview)

Comment on this tutorial