• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

HFSJ page 481 question 1

 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which is true about TLD files?
Ans is TLD files may be placed in any subdirectory of WEB-INF.But we are not supposed to place it under WEB-INF/classes.So is the answer right?Also Study kit say we can place it under any folder under the web application root.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'll answer if you take some time to thank people answering your questions (I'm thinking of yesterday's five posts)
 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
oh sorry ,Thought of replying but then I had to log out immedaitely
 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You have been very prompt in answering my question thanks a lot
 
Joe Harry
Ranch Hand
Posts: 10109
3
Eclipse IDE Mac PPC Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Satou,

I thank you all the time. You have been of great help in this forum and in javaranch!
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Renu, thank you. I was sure you were not ignoring fellow ranchers
(Jothi, thanks. And congrats for winning a book )

From the spec :
The container searches for all files with a .tld extension under /WEB-INF or a subdirectory, and inside JAR files that are in /WEB-INF/lib.
When examining a JAR file, only resources under /META-INF or a subdirectory are considered.
The order in which these files are searched for is implementation-specific and should not be relied on by web applications.

Also Study kit say we can place it under any folder under the web application root.

No, that's not true. And you don't want anybody to access it. (if you7re referring to SCWCD Study Kit, good luck to fix all the errors !)
 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But what if I dont mind others accessing it?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The container will not find it anyway. It does not look for TLDs in the context root. It only scans the directories I have mentioned above.
 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But this doesnt answer my question completely.If I can place it in a subdirectory of web-inf,I can as well place it in web-inf classes web-inf lib etc.But that is not permitted right?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sounds like it is permitted. Whatever directory under WEB-INF will do.
 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok...Thanks :-)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic