• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Eduardo Cobian's SCWCD Test Q28

 
Peter Masreblta
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1)Given the following web application deployment
descriptor:
<web-app>
<servlet>
<servlet-name>myServlet</servlet-name>
<servlet-class>MyServlet</servlet-class>
...
</servlet>
<servlet-mapping>
<servlet-name>myServlet</servlet-name>
<url-pattern>*.jsp</url-pattern>
</servlet-mapping>
which statements are true?
1) servlet-mapping element should be inside servlet element
2) url-pattern can't be defined that way.
3) if you make the http call: http://host/servlet/Hello.do
the servlet container will execute MyServlet.
4) It would work with any extension excepting jsp,html,htm
The answer given is 3), but I can not reproduce it.
Is this sopposed to be?
Thanks
 
ruijin yang
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Peter,
The answer 3) is correct.Of course,it is Hello.jsp
ruijin yang

[This message has been edited by ruijin yang (edited November 13, 2001).]
 
Peter Masreblta
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ruijin yang,
Which one is Hello.jsp?
quote:
--------------------------------------------------------------------------------
The answer 3) is correct.Of course,it is Hello.jsp
ruijin yang

--------------------------------------------------------------------------------


[This message has been edited by Peter Masreblta (edited November 13, 2001).]
 
ruijin yang
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Peter,
Of course,"Hello.do" should be "Hello.jsp"!
Originally posted by Peter Masreblta:
ruijin yang,
Which one is Hello.jsp?
quote:

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic