How does the Jsp Expressions works ? What happens at the
back?

Answer Posted / nowsheen tariq

jsp expressions is a normal java expression , when we write
the jsp expression in our jsp page like
<%=some expression%> then in the servlet ie generated by
jsp compiler the jsp expression will be placed without" "
in out.printmethod.

for example :

<%
int i=10,j=20,k=30;%>
k----> <%=k%>

in the servlet equivalent to above jsp page

out.print("k---->");
out.print(k);


like that at the back the jsp expression will be placed in
the out.print()without " " so that the value of the
expresssion will be evaluated and printed.

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can you disable the caching on the back button of a particular browser?

511


Which jsp method cannot be overridden?

520


Can we override jspinit method?

489


Explain the steps for creating custom tags in jsp?

481


Can a jsp page instantiate a serialized bean?

571






What are the events in jsp page?

488


Explain jsp and tell its uses?

532


What are the advantages of jstl?

486


What is difference between jsp and jstl?

473


difference betwwn 16 bit and 32 bit

1718


Why don’t we need to configure jsp standard tags in web.xml?

518


What is a javaserver pages (jsp)?

550


How can I declare methods within my jsp page?

522


Why are jsp pages the preferred api for creating a web-based client program?

544


What is jsp tag?

479