• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JspFragment

 
Akhil Maharaj
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

(a) As Per Page512,Ch 10 HFSJ , JspFragment can not have scriptlets .
I think JspFragment is nothng but all that is present inside custom tag


(b) I think I can write scriptlets inside a custom tag if I declare in the TLD as

<tag>
<name>fun>
<body-content>JSP</body-content>
</tag>


Both (a) and (b) are contradicting with each other. Can anybody explain what I am missing .

Thanks
Akhil
 
Mihai Radulescu
Ranch Hand
Posts: 918
IntelliJ IDE Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

A JspFragment is use like tag body for simple tags (SimpleTag interface). The SimpleTags accept like body only : empty, scriptless, tagdependent. The only one Tags which accept the JSP are the Classic Tags (Tag, TagIterator and TadBody inrterface).

Regards,
M
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic