Hey, good idea: +1 :P But I imagine it'd have to me more likes:

<bean:message key="text.welcome">
        <bean:message-arg0><bean:write name="un"
property="firstname"/></bean:message-arg0>
        <bean:message-arg1><bean:write name="un"
property="firstname"/></bean:message-arg1>
</bean:message>


Anthony

-----Original Message-----
From: Peter Alfors [mailto:[EMAIL PROTECTED]]
Sent: Friday, June 29, 2001 7:37 AM
To: [EMAIL PROTECTED]
Subject: Re: Custom tag question


If your question is just - "Is it possible"?  Then the answer is Yes.
However, if you are asking for the current tags to implement this, that is a
totally separate question.  That would take some re-work.

Pete

Aapo Laakkonen wrote:

> Is it possible to have custom tags that can have both child elements and
> attributes? I mean that in some cases it would be more elegant to use
> elements instead of attributes:
>
> <bean:message key="text.welcome">
>     <arg0><bean:write name="un" property="firstname"/></arg0>
>     <arg1><bean:write name="un" property="firstname"/></arg1>
> </bean:message>
>
> or:
>
> <bean:message>
>     <key>text.welcome</key>
>     <arg0><bean:write name="un" property="firstname"/></arg0>
>     <arg1><bean:write name="un" property="firstname"/></arg1>
> </bean:message>
>
> instead of this:
>
> <bean:message key="text.welcome"
>                         arg0="<% = un.firstname %>"
>                         arg1="<% = un.lastname %>"
> </bean:message>
>
> Or it would be even more flexible if you could use both of them (at the
same
> time).
> This was just an example and at least I have found many places where I'd
> like to
> use child elements instead of attributes.
>
> Or is it just me who thinks that those runtime expressions are pretty
ugly?
>
> -- Aapo Laakkonen, +358 (50) 33 99 682, ProjectCast Ltd, Helsinki,
Finland.

Reply via email to