latest reactions

spider
One way is to google for page which cont …
andy
you can find this tool here http://andy. …
Tjarko
Eej Walker, that's pretty cool, I will c …
Walker
Thanks for posting your thoughts. I modi …
Albert
Thanks !! …

Clicky Web Analytics
Use OpenDNS
ZERIGO DNS

Ultimate dns hosting based on pre-defined templates, DNS redirection and lot's more.

mxna feeds

CF101 Archive: September 2007 Object Oriented PizzaJob Opening for ColdFusion Developer at Arizona State UniversityMy New Experience Getting ColdFusion Builder 2 Console WorkingCF101 Archive: February 2007 Data Table GatewaysJob Opening for Sr. ColdFusion Developer in CA/ San Fernando ValleyColdFusion Supports HTTP Verbs PUT And DELETE (As Well As GET And POST)Best wishes for the new FuseboxCF101 Archive: January 2007 Data Access ObjectsOpen Source Conference For CFML DevelopersSkype Blocking Web Services with IIS, ColdFusion & RailoCF101 Archive: October 2006 Five Cool Things with ColdFusionGenerate a tag cloud from an RSS feed with ColdFusionColdFusion MeetUp: Cloudy with a Chance of Tests, with Mike HenkeReminder - Adobe CookbooksCF101 Archive: September 2006 A first look at FusionDebug

All files are strictly confidential: all information is classified.
© Copyright 2002 - 2012 mximize.com.
All right reserved.

Visit Carlos GallupaMXNA webfeed

How to strip HTML tags from a string?

You can get this result with the following regular expression

<cfsavecontent variable="str">
  <html>
    <body>
    This is the text you want
    </body>
  </html>
</cfsavecontent>

<cfset textstr = REReplace(str,'<[^>]*>','','all')>

<cfoutput>
  #textstr#
</cfoutput>

14711 viewed | 5 opinion(s)  | del.icio.us | Digg it | Tjarko @ 02/11/02 18:23 cet


Reactions:

JVirus wrote....

This is nice to know, too bad it isnt as easy to just have truncating text overlook HTML.

23 July 2007 22:42 cet  

Joshua Giese wrote.... (site)

wow, very simple. I was going to use a UDF i found here... http://www.opensourcecf.com/1/2006/11/Using-coldfusion-to-strip-some-or-all-HTML-tags-from-a-string.cfm

Your method is way more direct. thanks!

28 June 2008 1:15 cet  

Nick wrote....

This is awesome! Saved me a lot of time.

Cheers,
-Nick

31 July 2009 20:50 cet  

Michael wrote.... (site)

The site: http://www.feed-squirrel.com/index.cfm?evt=viewItem&ID=31247 seems to show a good function.

28 August 2009 16:39 cet  

james wrote.... (mail)

This works neat as you please.Very eligant solution.

18 May 2010 22:53 cet  

Leave your comment

Your name


Your url/website/link/email....


Some room for your reaction is placed here..



The answer to the ultimate question is?? (42 ;-))




URL en mail addresses are translated for you... life sometimes is that simple!!