Interview Questions and Answers for 'JSP' | Search Interview Question - javasearch.buggybread.com
Javasearch.buggybread.com

Search Interview Questions


 More than 3000 questions in repository.
 There are more than 900 unanswered questions.
Click here and help us by providing the answer.
 Have a video suggestion.
Click Correct / Improve and please let us know.
Label / Company      Label / Company / Text

   



Interview Questions and Answers for 'JSP' - 14 question(s) found - Order By Rating

 Q1. Mention the implicit objects in jspJSP
 This question was recently asked at 'IBM'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve          Asked in 1 Companies


 Q2. How to instantiate jsp variable from another jsp?JSP
Ans. using session attribute.

session.setAttribute("userId",userId);

in first jsp

int userId=session.getAttribute("userId");

in second jsp;

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve          Asked in 1 Companies


 Q3. What is EL in JSP?JSP
 This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     


 Q4. What is Method overloading ?Core Java
 This question was recently asked at 'jspiders'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve          Asked in 1 Companies      basic        frequent


 Q5. how do you share data between JSP and spring controller using Angular JS ?AngularJS
Ans. For JPS we can use modelAttribute and ModelAndView object to share data between JPS and Controller. In case of Angular JS, the angular js always get data in form of JSON and it can be accessed by REST WS. So the angular js share data with controller in the form of JSON.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     angularjs  jsp  spring controller     Asked in 1 Companies


 Q6. Difference between import and include directive in jspJava EE
 This question was recently asked at 'ADP'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     JSP  import and include directive in jsp     Asked in 1 Companies


 Q7. Difference between Include Directive and include action in jspJava EE
Ans. Include directive includes the file at translation time (the phase of JSP life cycle where the JSP gets converted into the equivalent servlet) whereas the include action includes the file at runtime.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     JSP  include directive  include action     Asked in 1 Companies


 Q8. Ho do you share / transfer variables between JSP pages ?Java EE
 This question was recently asked at 'UC Davis'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     jsp     Asked in 1 Companies


 Q9. What is a config Object?
Java EE
Ans. The config object is an instantiation of javax.servlet.ServletConfig and is a direct wrapper around the ServletConfig object for the generated servlet. This object allows the JSP programmer access to the Servlet or JSP engine initialization parameters such as the paths or file location.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     j2ee   servlet   jsp   servlet config   servletconfig   javax


 Q10. What is a pageContext Object?
Java EE
Ans. The pageContext object is an instance of a javax.servlet.jsp.PageContext object. The pageContext object is used to represent the entire JSP page. This object stores references to the request and response objects for each request. The application, config, session, and out objects are derived by accessing attributes of this object.The pageContext object also contains information about the directives issued to the JSP page, including the buffering information, the errorPageURL, and page scope.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     j2ee   servlet   jsp   pagecontext   page context


 Q11. What are the phases of the JSP life cycle ?Java EE
Ans. Translation of JSP PageCompilation of JSP PageClassloading (class file is loaded by the classloader)Instantiation (Object of the Generated Servlet is created).Initialization ( jspInit() method is invoked by the container).Reqeust processing ( _jspService() method is invoked by the container).Destroy ( jspDestroy() method is invoked by the container).

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     j2ee   servlets   servelets   web application   jsp   jsp life cycle   mindtree     Asked in 9 Companies


 Q12. Difference between the jsp scriptlet tag and jsp declaration tag?Java EE
Ans. The jsp scriptlet tag can only declare variables not methods whereas jsp declaration tag can declare variables as well as methods.

The declaration of scriptlet tag is placed inside the _jspService() method whereas The declaration of jsp declaration tag is placed outside the _jspService() method.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     j2ee   jsp   scriptlet tag   declaraation tag   web application


 Q13. What are JSP directives ? What are different types of directives ?Java EE
Ans. The jsp directives are messages that tells the web container how to translate a JSP page into the corresponding servlet.

There are three types of directives -

page directive
include directive
taglib directive

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     j2ee   servlets   servelets   web application   jsp   jsp ldirectives


 Q14. What are JSP Scriptlets?
Ans. Scriptlet allow to write Java code inside JSP like following

<% Java Code %>

 Help us improve. Please let us know the company, where you were asked this question :   

   Like         Discuss         Correct / Improve     jsp  jsp scriptlet  scriptlet



Help us and Others Improve. Please let us know the questions asked in any of your previous interview.

Any input from you will be highly appreciated and It will unlock the application for 10 more requests.

Company Name:
Questions Asked: