• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

What's truth about TLD

 
Mahajan Bhupendra
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
i got confused in one thing..
this is from jsp1_1-spec.pdf
<!ELEMENT tag (name, tagclass, teiclass?,bodycontent?, info?,attribute*) >
where there is no hyphen..
and this is from Ken's notes...
The element syntax is as follows:
<!ELEMENT tag (name, tag-class, tei-class?, body-content?, display-name?,
small-icon?, large-icon?, description?, variable*,attribute*,example?)>

so what should i consider correct in point of exam
at surprise both works...
i only tried <tagclass>
please answer soon....
i have to memorize...
Bhupendra Mahajan
 
Narasipur
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
It is
<!ELEMENT tag (name, tagclass, teiclass?, bodycontent?, info?, attribute*) >

This is from JavaServer Pages´┐Ż Specification Version 1.2
Hope this helps,
~s
 
Mahajan Bhupendra
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Narasipur
i think ur missing something..
actually i had downloaded old secs..
in new specs..
page 114
<!ELEMENT tag
(name, tag-class, tei-class?,
body-content?, display-name?, small-icon?, large-icon?,
description?, variable*, attribute*, example?) >
so hyphen is there...
Bhupendra Mahajan
 
Narasipur
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Actually, for SCWCD you need to go thru version 1.2 of the JSP specs.
And no, I'm not missing anything.
If you check page 239 of the version 1.2 spec, you'll find
" <!--The tag defines a unique tag in this tag library, defining:
- the unique tag/element name
- the subclass of javax.servlet.jsp.tagext.Tag implementation class
- an optional subclass of javax.servlet.jsp.tagext.TagExtraInfo
- the body content type (hint)
- optional tag-specific information
- any attributes
-->
<!ELEMENT tag (name, tagclass, teiclass?, bodycontent?, info?, attribute*) > "
Take you pick!
~s
 
Mahajan Bhupendra
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
so what we should consider for exam???
Bhupendra Mahajan
 
Tim Duncan
Ranch Hand
Posts: 150
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually, if we go to p.237 of the JSP 1.2 spec, the introduction there explains ...

This appendix includes the DTD for a tag library descriptor using JSP 1.1. All JSP 1.2 containers are required to accept such a TLD.

So the hyphenated versions come from the 1.2 TLD, and the un-hyphenated versions come from 1.1 TLD, but a 1.2 container must accept both!
Let's hope that Sun don't have any questions which force you to choose :-)
 
Narasipur
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, Tim!!!

~s
 
Mahajan Bhupendra
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanx Tim....
Bhupendra Mahajan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic