Home / CSE MCQs / JSP - CSE ::

CSE MCQs :: JSP - CSE

  1. Why use Request Dispatcher to forward a request to another resource, instead of using a sendRedirect?
  2. A.
    Redirects are no longer supported in the current servlet API
    B.
    Redirects are not a cross-platform portable mechanism
    C.
    The RequestDispatcher does not use the reflection API
    D.
    The RequestDispatcher does not require a round trip to the client, and thus is more efficient and allows the server to maintain request state

  3. Which is not a directive?
  4. A.
    include
    B.
    page
    C.
    export
    D.
    useBean

  5. Which attribute specifies a JSP page that should process any exceptions thrown but not caught in the current page?
  6. A.
    The ErrorPage Attribute
    B.
    The IsErrorPage Attribute
    C.
    Both A & B
    D.
    None of the above

  7. Which http method send by browser that asks the server to get the page only?
  8. A.
    get
    B.
    post
    C.
    option
    D.
    put

  9. JDBC is a ¦¦¦¦¦¦¦ interface, which means that it is used to invoke SQL commands directly
  10. A.
    low-level
    B.
    middle-level
    C.
    higher-level
    D.
    user

  11. 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?
  12. A.
    vs.Static HTML
    B.
    vs.Server-Side Includes
    C.
    vs.Pure Servlets
    D.
    Vs.JavaScript

  13. What is JDBC?
  14. A.
    java compiler
    B.
    Java API
    C.
    Java interpreter
    D.
    Both A and B

  15. Dynamic interception of requests and responses to transform the information is done by
  16. A.
    servlet container
    B.
    servlet config
    C.
    servlet context
    D.
    servlet filter

  17. What type of scriptlet code is better-suited to being factored forward into a servlet?
  18. A.
    Code that deals with logic that is common across requests
    B.
    Code that deals with logic that is vendor specific
    C.
    Code that deals with logic that relates to database access
    D.
    Code that deals with logic that relates to client scope

  19. This is a software distribution model in which applications are hosted by a vendor or service provider and made available to customers over a network, typically the Internet.
  20. A.
    Platform as a Service (PaaS)
    B.
    Infrastructure as a Service (IaaS)
    C.
    Software as a Service (SaaS)
    D.
    None