Tag library bodyContent is null
843838Aug 17 2005 — edited Aug 17 2005Hi,
I'm trying to greate a taglib that loops through the the body twice. There may be html in the body and I don't want that to be printed on the first iteration, only the second. I have the loop working fine I'm just stuck on the part about not printing the elnlosed html twice. How can this be achieved? I thought that I could maybe do something like:
public int doAfterBody() throws JspException {
try {
BodyContent body = getBodyContent();
body.clearBody();
.....
But getBodyContent() always seems to return null. Any ideas?
Thanks.
-Sam