> -----Original Message----- > From: David Schwartz [mailto:[EMAIL PROTECTED] > Sent: Thursday, April 01, 2004 1:03 PM > To: Jakarta Taglibs help (E-mail) > Subject: Finding a string within a string > > > I'm using jstl 1.2 with tomcat 4.1.24 > > Using the EL, is there a way to search for a "string within a string"? > > For example, I want to find "there" in the string "hello there world". > (something like indexOf(String str) )
Not in JSTL 1.0, but you could do this with the Jakarta String Taglib. See the <str:countMatches> tag: http://jakarta.apache.org/taglibs/doc/string-doc/string-1.0.1/index.html#cou ntMatches -- Martin Cooper > > David Schwartz > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
