Thanks for the reply. I have settled one the <foo:bar attrib1="baz" attrib2="<%=somevalue%>"> " /> approach but I too am not very happy with the available options. But for now I must keep moving forward. :-) ---------------------------------------------------------- Peter Giannopoulos, Software Developer Gemplus Software, Advanced Projects Group Phone: +15147322434 Fax: +15147322401 Gemplus Card International, Http://www.gemplus.fr I hear and I forget, I see and I remember, I do and I understand. ----------------------------------------------------------- -----Original Message----- From: Stefan Riegel [mailto:[EMAIL PROTECTED]] Sent: April 27, 2001 5:38 AM To: [EMAIL PROTECTED] Subject: AW: A bit of newbie question Hello, Peter Giannopoulos, funny, but I did ask a similar question almost the same time :-) Peter Alfors confirmed, that their is no way to use Custom Tags as attribute values in Custom Tags. Now we have some design choices: 1. Use scripting: <foo:bar attrib1="baz" attrib2="<%=somevalue%>"/> This solution is the most flexible and less complicated but the users of Your tags need to know Java coding. 2. Use some approaches similar to James Strachans proposal: <foo:bar attrib1="baz"> <foo:othertag attrib1=""> </foo:bar> It can be useful in some situations but the "othertag" has to know about, that it is beeing used as an attribute. 3. Use a nested attribute tag similar to this: <foo:bar attrib1="baz"> <foo:attribute name="attrib2"> <foo:othertag /> </foo:attribute> </foo:bar> This approach needs also some special coding especially if you want to permit both possibilities to set the attrib2 value (as common attribute with the value supplied as a string or attribute tag with a value supplied as another tag). The use of such tags are also very verbos. 4. ... More ideas? ... I'am not very happy with none of this possibilities but JSP Custom Tags are still very usefull. For me it is the best on the road :-) Regards Stefan Riegel > -----Urspr�ngliche Nachricht----- > Von: Peter Giannopoulos [mailto:[EMAIL PROTECTED]] > Gesendet: Donnerstag, 26. April 2001 20:50 > An: [EMAIL PROTECTED] > Betreff: A bit of newbie question > > > Hello all, > > I am new to the taglib development world so please bare with me, if I > sometimes seem to ask silly questions. :-) > > That being said, I would love to know if there is a way to > use a custom tag > within another custom tag (as an attribute value) > > For example something like (please let me know if I'm being > stupid here...is > there a better way?) > > <foo:bar attrib1="baz" attrib2=" <foo:othertag attrib1=""> " /> > OR > > <foo:bar attrib1="baz" attrib2="<%=somevalue%>"> " /> > ----> I really would rather avoid any code between <% and > %> on the jsp > page. > > Basically the page will invoke itself and every time it does > it passes to > itself a incremented counter. Based on the value of the > counter the <foo:bar > /> tag should modify it's behaviour. > > Any suggestions? Or maybe even pointers to documentation that > deals with > this kind of thing? Is it even reasonable want to do this? > > > > Thanks, > > --------------------------------------------------------- > Peter Giannopoulos, Software Developer > Gemplus Software, Advanced Projects Group > > Phone: +15147322434 > Fax: +15147322401 > Gemplus Card International, Http://www.gemplus.fr > > > > I hear and I forget, > I see and I remember, > I do and I understand. > > > > ----------------------------------------------------------- >
BEGIN:VCARD VERSION:2.1 N:Giannopoulos;Peter FN:Peter Giannopoulos ORG:Gemplus Canada inc.;CTO Group TITLE:Software Developer NOTE;ENCODING=QUOTED-PRINTABLE:=0D=0A--- Codito, ergo sum - "I code, therefore I am" --- TEL;WORK;VOICE:514-732-2434 TEL;HOME;VOICE:N/A TEL;CELL;VOICE:N/A TEL;PAGER;VOICE:N/A TEL;WORK;FAX:514-732-2301 ADR;POSTAL:;;3 Place du Commerce;Ile des soeurs;Quebec;H3E 1H7;Canada LABEL;POSTAL;ENCODING=QUOTED-PRINTABLE:3 Place du Commerce=0D=0AIle des soeurs, Quebec H3E 1H7=0D=0ACanada URL:http://www.gemplus.com EMAIL;PREF;INTERNET:[EMAIL PROTECTED] REV:20000926T190330Z END:VCARD
