JSP And Servlet Mcqs
Q.1: How can you make the JSP class implement the SingleThreadModel interface?I
A. <%@ page isThreadSafe=
B. <%@ page ThreadSafe=
C. <%@ page ThreadSafe=
D. <%@ page isThreadSafe=
Q.2: javax.servlet.jsp.JspPage extends which of the following interfaces?D
A. GenericServlet
B. HttpServlet
C. Servlet
D. HttpJspPage
Q.3: Which of the following is an INVALID attribute for tag directive?A
A. dynamic-attributes
B. display-name
C. body-content
D. tag-attributes
Q.4: What is the limit of data to be passed from HTML when doGet() method is used?M
A. 8k
B. 2k
C. 4k
D. 1k
Q.5: Where in JSP page source can EL functions be used? 3
A. In the body of a tag where body-content is set to tagdependent>
B. Within a JSP expression
C. Within a JSP scriptlet
D. In the body of a tag where body-content is set to JSP5
Q.6: Which of the following object scope is defined as follows : Objects with this scope are accessible from pages processing requests in the same application as the one in which they were created?
A. session
B. page
C. application
D. request
Q.7: Which of the following is not a valid java bean (POJO) scope in JSP?D
A. response
B. session
C. request
D. application
Q.8: Which of the following is a non-idempotent HTTP method6
A. HEAD
B. PUT
C. POST
D. DELETE
Q.9: Why do you get this error? NoClassDefFoundError: org.apache.commons.lang.StringUtils. 1. The given class could not be found. 2. The given class could be found, but something went wrong when initializing it 3. None of them
A. 1
B. 2
C. No Option
D. No Option
Q.10: Which of the following is valid about 'page' JSP directive?;
A. Includes the contents of a file into the JSP at translation time@
B. Controls properties of the entire application-
C. Makes a custom tag library available within the including page>
D. Controls properties of the JSP

Related Mcqs

All Subject Mcqs