* Remove all tags from an HTML text * expC1 Content FUNCTION ExtractTag PARAMETER tcContent LOCAL lnStart,lnStop lnStart=1 lnStop=0 tcContent=ALLTRIM(tcContent) DO WHILE lnStart>0 lnStart=AT('<',tcContent) lnStop=AT('>',SUBSTR(tcContent,lnStart)) IF lnStart=0 OR lnStop=0 EXIT ENDIF IF lnStart=1 tcContent=SUBSTR(tcContent,lnStop+1) ELSE tcContent=LEFT(tcContent,lnStart-1)+SUBSTR(tcContent,lnStart+lnStop) ENDIF ENDDO * Now, for all the rest, we need to make sure, that we don't have a single < in the string tcContent=STRTRAN(tcContent,'<','<') RETURN tcContent