This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Little Book of Impediments (e-book only) and have Tom Perry on-line!
See this thread for details.
Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

jsp:root question

 
Andreas Falley
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There's something that I don't understand. I've been studying for the scwcd using the Deshmukh book.
In the sample code that they provide, they set the
jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"
version="1.2"
But I don't have my linux box (where I code from) online, yet the code runs fine. Indeed, it looks like
Sun doesn't have the page online either.
What is the use of the attributes in this tag? Is any info in the root tag really manditory? It seems to work fine with tomcat4 without the info.
What's going on? Or is tomcat4 just smarter than other servers?
Many thanks!
- Andreas
[LIST]
 
Paul McKenna
Ugly Redneck
Ranch Hand
Posts: 1006
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Andreas Falley:

jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"
version="1.2"
But I don't have my linux box (where I code from) online, yet the code runs fine. Indeed, it looks like
Sun doesn't have the page online either.
[LIST]

Hi..
The attributes specified tell the parser that the document is defined using a particular namespace. Any JSP parser would automatically understand the attributes defined and would parse it accordingly. If you try to parse this file using an external parser, you are likely to encounter an error stating that schema definition not found.
These attributes are merely a way of telling the parser that already understands the document, "look.. I'm JSP document, version 1.2"
Thanks
SR
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic