aspose file tools*
The moose likes JSP and the fly likes bodycontent - JSP or tagdependent? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "bodycontent - JSP or tagdependent?" Watch "bodycontent - JSP or tagdependent?" New topic
Author

bodycontent - JSP or tagdependent?

Ranadhir Nag
Ranch Hand

Joined: Mar 09, 2006
Posts: 138
I am new to custom tags and face a conceptual problem.
I have nestedtags in my JSP as follows:
<user:useragevalidation id="user">
<user:NotValidAge>You are not of valid age.</user:NotValidAge>
<user:validage>Yuo are of valid age.</user:validage>
</user:useragevalidation>

Now when i define the bodycontent of outer tag(useragevalidation) as tagdependent,I see that the inner tags are not parsed at all (dostarttag/doafterbody of inner tags are not called).
However when i change the bodycontent property to JSP,the inner tags are processed for dostarttag/doafterbody etc.,without any other change in code anywhere.

What causes this difference?Why does the tagdependent property not work in this case?
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61224
    
  66

That's exactly what tagdependent means; that you are planning to process the tag body and the JSP engine should not.

If that's not what youwant, don't use it.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
wood burning stoves
 
subject: bodycontent - JSP or tagdependent?