strip form input of certain characters 
Author Message
 strip form input of certain characters

Hi, there,

i have written an asp script that gathers all form data an sends an email
all works fine,

accept i want to strip the comments field (text area) of any html tags,  if
user happens to use them,

what the bext way to do this ?

cheers in advance,

julian



Wed, 19 Nov 2003 07:24:58 GMT  
 strip form input of certain characters
Function StripHTML(field)
    With New RegExp
        .Pattern = "</?[a-z]+[^>]*>"
        .Global = True
        .IgnoreCase = True
        StripHTML = .Replace(field,"")
    End With
End Function


| Hi, there,
|
| i have written an asp script that gathers all form data an sends an
email
| all works fine,
|
| accept i want to strip the comments field (text area) of any html
tags,  if
| user happens to use them,
|
| what the bext way to do this ?
|
| cheers in advance,
|
|
| julian
|
|
|
|



Wed, 19 Nov 2003 12:47:28 GMT  
 strip form input of certain characters
cheers  Walter


Quote:
> Function StripHTML(field)
>     With New RegExp
>         .Pattern = "</?[a-z]+[^>]*>"
>         .Global = True
>         .IgnoreCase = True
>         StripHTML = .Replace(field,"")
>     End With
> End Function



> | Hi, there,
> |
> | i have written an asp script that gathers all form data an sends an
> email
> | all works fine,
> |
> | accept i want to strip the comments field (text area) of any html
> tags,  if
> | user happens to use them,
> |
> | what the bext way to do this ?
> |
> | cheers in advance,
> |
> |
> | julian
> |
> |
> |
> |



Wed, 19 Nov 2003 17:11:27 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Line Input strips out NULL characters

2. Need Regular Expression to strip non-numeric characters from string

3. how to strip white spaces, line characters from xml file (written by dataset.writexml)

4. Stripping Unprintable Characters

5. Easy Way of Stripping Out Characters?

6. Stripping Out Unprintable Characters

7. Stripping out DBCS Characters

8. How do I strip a character in VB?

9. HELP! Stripping NON ALPHA characters from a string

10. Easy Way of Stripping Out Characters?

11. Stripping Unprintable Characters

12. Stripping Out Unprintable Characters

 

 
Powered by phpBB® Forum Software