• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

some jsp questions

 
Rasika Chitnis
Ranch Hand
Posts: 131
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1) why <%@ page %> is not a valid directive, considering that all attrinutes are optional ?
2) should you specify a protocol e.g. jar:// if you want to specify jar file under taglib-location tag in web.xml ? I see an example in manning book (without any jar://) on page 288 which is as follows :
<taglib>
<taglib-uri>
http://www.manning.com/samplelib
</taglib-uri>
<taglib-location>
yourLibs/sample.jar
</taglib-location>
</taglib>
However, I came across such question in one of the mock exams and the explanation given was if you want to use a jar file as the location of the .tld file in web.xml, then you have to use an absolute url that includes the protocol such as jar://
3) if jsp:getProperty tag is used before jsp:setProperty, what values will be printed ? I think the values will be the default values i.e. Objects will be initialized to null and primitive data types will be initialized to zero (for int, long), false for boolean etc. Is that right ?
thanks in advance
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic