• Post Reply Bookmark Topic Watch Topic
  • New Topic

Not able to get the bodycontent

 
Arun Kumar
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using the BodyTagSupport and ......

I have all the other things right like

<bodycontent>JSP</bodycontent> in the tld file and

doStartTag() returns the EVAL_BODY_INCLUDE

I am also invoking the tag with the body but, I can't get the body content.

If I try using the getBodyContent() in the doEndTag() it returns null, I am not sure what is wrong.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65530
108
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you implementing doAfterBody()?
 
Arun Kumar
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No I am not I am relying on the default return SKIP_BODY behaviour.
 
Arun Kumar
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
sorry guys i found the problem

doStartTag() returns the EVAL_BODY_INCLUDE, that was the problem, I changed it to return EVAL_bODY_BUFFERED and it works now.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!