• Post Reply Bookmark Topic Watch Topic
  • New Topic

tags as other tags' attribute value  RSS feed

 
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, people,

Maybe this is a recurring question but I didn't manage to find the right keywords, so I'm gonna (re)post it.

I learned that custom tags don't accept other tags as their attribute values. So I can't write something like:

<myTag rocess att1='<bean:write name="att1id"/>'
att2='<bean:write name="att2id"/>'
att3 ='<bean:write name="att3id"/>'
/>
Is that correct?

The problem is that I changed the bean:write tags above to scripting variables (like <%=att1id%> but the tag handler is still getting the string "<%=att1id%>" instead of the content of the string attribute (like the parser is not parsing).

Can anybody help me?

Thanks in advance,

Kaiser
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you want your custom tag to accept a scriptlet as one of it's attributes, you must include:

<rtexprvalue>true</rtexprvalue>

with the definition of that attribute in your .tld file.
 
Kaiser Lautern
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Merril,

That's exactly what was missing in my tld to make it work.

Kaiser
 
Something must be done about this. Let's start by reading this tiny ad:
ScroogeXHTML 7.1 - RTF to HTML5 / XHTML converter
https://coderanch.com/t/690611/ScroogeXHTML-RTF-HTML-XHTML-converter
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!