Here's link to the man page:
http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JSPTags5.html

On Wed, Feb 10, 2010 at 8:39 PM, Richard Hauswald
<[email protected]> wrote:
> Hi,
> what about using jsp tag files? You could create your own link tag
> file and include the choose statement there. Here is a example for a
> form field:
> /WEB-INF/tags/FormRowText.tag
> <%@ include file="/WEB-INF/jsp-includes/taglibs.jsp"%>
>
> <%@ attribute name="name" required="true" type="java.lang.String"%>
>
> <s:label for="${name}"></s:label>&nbsp;<s:text name="${name}"
> formatPattern="#,##0.00"></s:text>
> <br />
> <s:errors field="${name}" />
>
> Make sure this file is placed under /WEB-INF/tags/ and don't forget to
> include the taglib:
> <%@ taglib prefix="ct" tagdir="/WEB-INF/tags" %>
>
> Then you can use this tag like any other jsp tag:
> <ct:FormRowText name="userName"/>
>
> Regards,
> Richard
>
>
> On Wed, Feb 10, 2010 at 8:06 PM, Ross Sargant <[email protected]> wrote:
>> Hi,
>>   This is more of a general JSP/EL question then a stripes one but I can't
>> seem to find an answer.
>> I have a layout definition that uses a stripes:link tag. When I call the
>> layout I pass an argument to set the class on the link.
>>
>> Is there any short-hand way I can set the class attribute on the
>> stripes:link tag only when the argument is not empty?
>> This general issue crops of often for me and I'd like to avoid doing this
>> all the time:
>>
>> <c:choose>
>>   <c:when test="${!empty linkClass}">
>>    <stripes:link class="${linkClass}".../>
>> </c:when>
>>   <c:otherwise>
>>     <stripes:link .../>
>>   </c:otherwise>
>> </c:choose>
>>
>> The best I've got so far is
>>
>> <stripes:link class="${!empty linkClass ? linkClass:' ' }"/>
>>
>> Which is much better but still not exactly what I want since it outputs an
>> empty "class" attribute for the empty case.
>>
>> Thanks!
>>
>>
>> --
>> Ross Sargant
>> Software Engineer
>> p: 954-623-6015 x2108
>> email: [email protected]
>>
>> TVR Communications LLC
>> 541 S. State Road 7,Suite 5,Margate, Florida,33068
>>
>> http://www.tvrc.com
>>
>>
>> ------------------------------------------------------------------------------
>> SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
>> Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
>> http://p.sf.net/sfu/solaris-dev2dev
>> _______________________________________________
>> Stripes-users mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/stripes-users
>>
>>
>
>
>
> --
> Richard Hauswald
> Blog: http://tnfstacc.blogspot.com/
> LinkedIn: http://www.linkedin.com/in/richardhauswald
> Xing: http://www.xing.com/profile/Richard_Hauswald
>



-- 
Richard Hauswald
Blog: http://tnfstacc.blogspot.com/
LinkedIn: http://www.linkedin.com/in/richardhauswald
Xing: http://www.xing.com/profile/Richard_Hauswald

------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
Stripes-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-users

Reply via email to