what is the difference between page and pageContext
implicit variables

Answer Posted / rajesh rakam

Page:
The implicit variable page is of class java.lang.Object and
it refers to instance of generated servlet. It is declared as
Object page=this
<%= ((Servlet)page).getServletInfo() %> is valid

pageContext:
pageContext variable is of type
javax.servlet.jsp.PageContext. The PageContext class is the
abstract class and JSP engine vendor provides its concrete
subclass.
->Store reference to implicit objects,
->Provide method to get and set attributes in different scopes.
->Provide convenience methods for transferring request to
other resources in web application.
PageContext.forward(&#65533;other.jsp&#65533;);

Is This Answer Correct ?    5 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is container struts2?

529


What is xml based validation in struts2?

562


What is interceptor struts2?

534


What is the use of struts config xml file?

483


How do u provide security to ur project?(Banking domain project)

4448






Which components are available using actioncontext map?

724


Explain about logic match tag?

570


What is the differences between struts1 and struts2?

532


How can we display validation errors on jsp page?

539


What is the purpose of @results annotation?

720


Where can I get a copy of struts?

542


Can we handle exceptions in Struts programmatically?

517


Is Struts Framework part of J2EE?

621


How can we upload files in Struts2 application?

588


What is the design role played by struts?

554