JSP - Java (MCQ) questions and answers

Dear Readers, Welcome to JSP multiple choice questions and answers with explanation. These objective type JSP questions are very important for campus placement test and job interviews. Specially developed for the Networking freshers and professionals, these model questions are asked in the online technical test and interview of many IT companies.

1)   What technique is used for the authentication mechanism in the servlet specification?
- Published on 19 Oct 15

a. Role Based Authentication
b. Form Based Authentication
c. Both A & B
d. None of the above
Answer  Explanation 

ANSWER: Role Based Authentication

Explanation:
No explanation is available for this question!


2)   Which attribute specifies a JSP page that should process any exceptions thrown but not caught in the current page?
- Published on 19 Oct 15

a. The ErrorPage Attribute
b. The IsErrorPage Attribute
c. Both A & B
d. None of the above
Answer  Explanation 

ANSWER: The ErrorPage Attribute

Explanation:
No explanation is available for this question!


3)   Which Error Handling in Java handles runtime errors with exceptions, If an exception is not caught in your JSP or Servlet, Resin will use a special error page to send results back to the browser, Resin uses a default error page unless you explicitly provide an error page yourself?
- Published on 22 Jul 15

a. Client Request Time Processing Errors
b. Compilation Time Processing Errors
c. JSP Translation Time Processing Errors
d. None of the above
Answer  Explanation 

ANSWER: Client Request Time Processing Errors

Explanation:
No explanation is available for this question!


4)   The ASP and JSP technologies are quite similar in the way they support the creation of Dynamic pages, using HTML templates, scripting code and components for business logic.
- Published on 22 Jul 15

a. True
b. False
Answer  Explanation 

ANSWER: True

Explanation:
No explanation is available for this question!


5)   Which can generate HTML dynamically on the client but can hardly interact with the web server to perform complex tasks like database access and image processing etc. in JSP?
- Published on 22 Jul 15

a. vs.Static HTML
b. vs.Server-Side Includes
c. vs.Pure Servlets
d. Vs.JavaScript
Answer  Explanation 

ANSWER: Vs.JavaScript

Explanation:
No explanation is available for this question!


6)   In JSP Action tags which tags are used for bean development?
- Published on 21 Jul 15

a. jsp:useBean
b. jsp:setPoperty
c. jsp:getProperty
d. All mentioned above
Answer  Explanation 

ANSWER: All mentioned above

Explanation:
No explanation is available for this question!


7)   Which two interfaces does the javax.servlet.jsp package have?
- Published on 21 Jul 15

a. JspPage
b. HttpJspPage
c. JspWriter
d. PageContext
e. Both A & B
Answer  Explanation 

ANSWER: Both A & B

Explanation:
No explanation is available for this question!


8)   Which of the following is an advantage of the statement – Separation of business logic from JSP ?
- Published on 20 Jul 15

a. Custom Tags in JSP
b. JSP Standard Tag Library
c. All the above
d. None of the above
Answer  Explanation 

ANSWER: Custom Tags in JSP

Explanation:
No explanation is available for this question!


9)   JSPs eventually are compiled into Java servlets, you can do as much with JSPs as you can do with Java servlets.
- Published on 20 Jul 15

a. True
b. False
Answer  Explanation 

ANSWER: True

Explanation:
No explanation is available for this question!


10)   How many jsp implicit objects are there and these objects are created by the web container that are available to all the jsp pages?
- Published on 20 Jul 15

a. 8
b. 9
c. 10
d. 7
Answer  Explanation 

ANSWER: 9

Explanation:
No explanation is available for this question!


1 2 3