Tim Ringwood wrote:
> If all else fails that's a pretty easy custom tag.
> 
> See WROX's JSP book. They have examples regarding how
> to change the content a BODY of a tag.

No, I'm afraid not. If I read the requirement correctly, Ben wants
a way to evaluate a custom action that's not in the requested page
but rather in a String available to the page at runtime. There's
nothing in the JSP specifaction that allows you to dynamically
invoke the tag handler for a custom action at runtime.

That said, everything is possible. You could use a custom tag that
parses the string, locates the tag handler matching the custom
action so some means (no support for doing this generically in the
spec), and calls all setters and doXXX() methods according to the
rules defined in the spec. I strongly discourage such a solution,
though.

Ben, if you tell us what the end goal is, maybe we can suggest an
alternative solution.

Hans

> --- Ben Pezzei <[EMAIL PROTECTED]> wrote:
> 
>>hi folx
>>
>>sorry, if this is a bit OT, but perhaps someone is
>>able
>>to help me with this
>>
>>i have the following problem (extremely stripped
>>down ;):
>>
>>Is there a way to evaluate if a String contains a
>>tag lib
>>and if yes, how can i parse it.
>>
>>for example
>>
>>String s = "This is just a <a:link
>>target="somwehere">Link</a:link>";
>>
>>where <a:link> is a custom tag  with tld and
>>corresponding tag class.
>>
>>now i want to transform the String s to "This is
>>just a 
>><a href="somewhere?id=myid">link</a>". This
>>transformation
>>is actually done by the tag-class. 
>>
>>is this possible? and if yes, can someone point me
>>to a 
>>webpage or something? Or is there another way of
>>accomplishing this
>>(no regex)?
>>
>>I tried around with pagecontext, bodycontent and so
>>on but without
>>any success. also google'ing around was not
>>helpfull.
>>
>>any help or hint would be great
>>
>>greetings
>>ben
>>
>>--
>>To unsubscribe, e-mail:  
>><mailto:[EMAIL PROTECTED]>
>>For additional commands, e-mail:
>><mailto:[EMAIL PROTECTED]>
>>
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Health - Feel better, live better
> http://health.yahoo.com
> 
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
> 


-- 
Hans Bergsten           [EMAIL PROTECTED]
Gefion Software         http://www.gefionsoftware.com
JavaServer Pages        http://TheJSPBook.com


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to