• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

a doubt on JspFragment

 
Sayak Banerjee
Ranch Hand
Posts: 292
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
Could any one help me out with this? On page 512(2nd paragraph) in HFSJ it sez "The crucial thing you must remember about JspFragment is that it must NOT contain scripting elements! It can contain template text, standard and custom actions, and EL expressions, but no scriptlets, declarations, or scripting expressions."
Now, if that is true, what about the TLD subelement <body-content> inside the <tag> element which says:
<body-content>JSP</body-content>
As far as I understand the above statement would hold good if we have something like <body-content>scriptless</body-content> in the TLD.Could someone please explain this?

Thanks in advance.
 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JSPFragment comes in to picture only in SimpleTags in custom tags its BodyContent.And in SimpleTags you are not supposed specify the body-content as JSP,which is infact a limitation of SimpleTags
 
Sayak Banerjee
Ranch Hand
Posts: 292
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I see...so that means in that case I'd have to resort to classic tags...am I right?
 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yes even tag files cant be used as it also has got the same restriction
 
Gowher Naik
Ranch Hand
Posts: 643
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For simple tags following values for body-content are used only
empty
tagdependent
scriptless


For custom tags following values for body-content are valide only
empty
tagdependent
JSP


Please correct me if i am not correct.
 
Renu Radhika
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
scriptless can also be used for custom tags.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic