- JSP - Home
- JSP - Overview
- JSP - Environment Setup
- JSP - Architecture
- JSP - Lifecycle
- JSP - Syntax
- JSP - Directives
- JSP - Actions
- JSP - Implicit Objects
- JSP - Client Request
- JSP - Server Response
- JSP - Http Status Codes
- JSP - Form Processing
- JSP - Writing Filters
- JSP - Cookies Handling
- JSP - Session Tracking
- JSP - File Uploading
- JSP - Handling Date
- JSP - Page Redirect
- JSP - Hits Counter
- JSP - Auto Refresh
- JSP - Sending Email
- JSP - Standard Tag Library
- JSP - Database Access
- JSP - XML Data
- JSP - Java Beans
- JSP - Custom Tags
- JSP - Expression Language
- JSP - Exception Handling
- JSP - Debugging
- JSP - Security
- JSP - Internationalization
- JSP Useful Resources
- JSP - Questions and Answers
- JSP - Quick Guide
- JSP - Useful Resources
- JSP - Discussion
JSP Online Quiz
Following quiz provides Multiple Choice Questions (MCQs) related to JSP Fundamentals. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.
Q 1 - request is instance of which class?
Answer : C
Explaination
request is object of HttpServletRequest.
Answer : B
Explaination
jsp is a server side technology.
Answer : A
Explaination
Yes, all servlets are required to be mapped/configured in web.xml
Q 4 - Which of the following is true about page scope?
A - Object created with request scope are accessible only from the page in which they are created.
B - Object created with request scope are accessible only from the pages which are in same session.
Answer : A
Explaination
Object created with request scope are accessible only from the page which they are created. Object data gets lost once response is returned or request is forwarded.
Q 5 - config is instance of which class?
A - javax.servlet.ServletContext
Answer : B
Explaination
The config object is an instantiation of javax.servlet.ServletConfig and is a direct wrapper around the ServletConfig object for the generated servlet.
Q 6 - Which of the following is true about autoFlush Attribute?
Answer : C
Explaination
The autoFlush attribute specifies whether buffered output should be flushed automatically when the buffer is filled, or whether an exception should be raised to indicate buffer overflow.
Q 7 - Which of the following is true about isThreadSafe Attribute?
A - The isThreadSafe option marks a page as being thread-safe.
Answer : D
Explaination
The isThreadSafe option marks a page as being thread-safe. By default, all JSPs are considered thread-safe. If you set the isThreadSafe option to false, the JSP engine makes sure that only one thread at a time is executing your JSP.
Q 8 - Which of the following is true about <jsp:useBean> action?
Answer : C
Explaination
useBean action first searches for an existing object utilizing the id and scope variables. If an object is not found, it then tries to create the specified object. useBean is used to load java beans in jsp page.
Q 9 - What is Internationalization?
A - Internationalization means creating international content on a website.
C - Internationalization refers to creating local content on a website.
Answer : B
Explaination
Internationalization means enabling a web site to provide different versions of content translated into the visitor's language or nationality.
Q 10 - Which of the following is true about <c:param> tag?
A - The <c:param> tag allows proper URL request parameter to be specified with URL.
B - The <c:param> tag does any necessary URL encoding required
Answer : C
Explaination
The <c:param> tag allows proper URL request parameter to be specified with URL and it does any necessary URL encoding required.