• Post Reply Bookmark Topic Watch Topic
  • New Topic

facelets and XHTML  RSS feed

 
vinutha
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why we need to use xhtml in facelets and what are the benifits of using xhtml pages in facelets.
 
Tim Holloway
Bartender
Posts: 18531
61
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HTML doesn't have a rigorous set of encoding rules the way XML does. For example, in HTML, it is perfectly legal and quite common to code a <p> tag by itself with no corresponding closure.

XHTML is a form of HTML that is constrained to follow the forms of XML, and thus can be easily parsed by an XML parser, A <p> by itself would be invalid - you'd have to code <p></p> or <p/>.

Because XHTML can be processed by an XML parser, the Facelets framework can use an off-the-shelf XML processor to do its work instead of having to puzzle out the ambiguous structures that are common to HTML.

I think that in context to your specific question, the advantage of the xhtml pages is that they can be assembled into display panes using the Facelets tiling facility.
 
vinutha
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Tim,

Thanks for your explaination...........
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!