• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Order of elements in web.xml

 
Pavan Kumar Tammana
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
Can anyone tell me the order of elements we declare in deployment descriptor? I actually thought that the order doesn't matter. But when i was doing the mock exams i have seen some questions on this. I am actually using a SWT(Standard Web Toolkit) a plug-in for eclipse. Normally the tool alerts me if the order in web.xml is not correct, because it has the reference to the dtd in the deployment descriptor and i guess the validation is done by referring to the dtd. HFSJ book also doesn't talk anything regarding this. So can anyone help me with this???

Bates/Kathy/Bryan,
It will be a lot helpful if you can shed some light on this??

Thanks,
Pavan Kumar Tammana
 
Daniel Dalton
Ranch Hand
Posts: 146
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
it doesn't matter with 2.4 - it does with 2.3

You are probably looking at old questions for the 2.3 spec.
 
Daniel Dalton
Ranch Hand
Posts: 146
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
oh - if you're using a DTD, it probably thinks it's 2.3

do you open web.xml like this ?:




or like this

 
Pavan Kumar Tammana
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Daniel,
Sorry i meant xsd, i am referring to 2.4 version, so i am using the xsd in my web.xml. But don't you think during the schema validation it checks for the order, because i get errors/warnings if i shift the order of some elements.

Thanks,
Pavan Kumar Tammana.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic