The following function will strip all html tags from a text. Can be usefull for a lot of things where you don´t want any html code to screw up the design. Found it somewhere on the internet a few years back, very usefull!
Function StripHTML(ByRef asHTML)
Dim loRegExp ‘ Regular Expression Object‘ Create built In Regular Expression object
Set loRegExp = New RegExp
loRegExp.Global = True
‘ Set the pattern To look For HTML tags
loRegExp.Pattern = “<[^>]*>”‘ Return the original String stripped of HTML
StripHTML = loRegExp.Replace(asHTML,” “)‘ Release object from memory
Set loRegExp = NothingEnd function
To use this function in your page, just do the following (also be shure you included the function in your page):
Dim MyString
MyString = StripHTML(<yourstring>)
Replace <yourstring> with your own input.


Thx for the code.