Forget it - I needid to add the commons jar. Thanks. ----- Original Message ----- From: "Stefan" <[EMAIL PROTECTED]> To: "Tag Libraries Users List" <[EMAIL PROTECTED]> Sent: Friday, October 11, 2002 12:45 AM Subject: Re: Is there a way to call java.lang.String.substring on a <c:out ?
> Hi, > > I just installed the string taglib and tried the simple example as found in > the docs: > > <str:substring start="4" end="8">The tree is green.</str:substring> > > And I get this error: > > org/apache/commons/lang/NumberUtils > > I am using Resin 2.1.4 and placed the string.jar file into the web > applications WEB-INF\lib folder and added the discriptor file to: > > WEB-INF\classes\tlds > > And finally I added this to the web.xml file: > > <taglib> > <taglib-uri>http://jakarta.apache.org/taglibs/string-1.0</taglib-uri> > <taglib-location>/WEB-INF/string.tld</taglib-location> > </taglib> > > > Any ideas what I am doing wrong? > > Thanks > > ----- Original Message ----- > From: "Tim Kettering" <[EMAIL PROTECTED]> > To: "Tag Libraries Users List" <[EMAIL PROTECTED]> > Sent: Friday, October 11, 2002 12:17 AM > Subject: Re: Is there a way to call java.lang.String.substring on a <c:out ? > > > > > > http://jakarta.apache.org/taglibs/doc/string-doc/intro.html > > > > I'd suggest using the Strings taglib. Its really very nice, and comes > with > > a whole lot of other goodies you can use as well, rather than making a > > one-off bean method that does the same thing. > > > > <str:substring start="4" end="8"> > > <c:out value="${param.name}"/></str:substring> > > > > Or something like that. > > > > > > > So I would wrap the <c:out value="${}}"/> tag with a JSTL string taglib > or > > > perhaps a bean method that returns a string like so: > > > > > > <%= myBean.myStringMethod(<c:out value="${param.name}}"/>) %> > > > > > > > > > Thanks > > > > > > > > > ----- Original Message ----- > > > From: "Shawn Bayern" <[EMAIL PROTECTED]> > > > To: "Tag Libraries Users List" <[EMAIL PROTECTED]> > > > Sent: Thursday, October 10, 2002 11:36 PM > > > Subject: Re: Is there a way to call java.lang.String.substring on a <c: > out > > > ? > > > > > > > > >> On Thu, 10 Oct 2002, Stefan wrote: > > >> > > >>> So is there a way to extract a sub string from the result of a <c:out > > >>> value="${}}"/> tag? > > >> > > >> No, not alone; you'd need to use the String Taglib or handle it with a > > >> servlet or other custom Java logic (e.g., a bean or servlet). > > >> > > >> -- > > >> Shawn Bayern > > >> "JSTL in Action" http://www.jstlbook.com > > >> > > >> > > >> -- > > >> To unsubscribe, e-mail: > > > <mailto:[EMAIL PROTECTED]> > > >> For additional commands, e-mail: > > > <mailto:[EMAIL PROTECTED]> > > >> > > > > > > > > > -- > > > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > > > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > > > > > -- > > Tim Kettering > > [EMAIL PROTECTED] > > > > > > -- > > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > > > -- > To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>