Elimination html tags from text when posting

Discussions

Web tier: servlets, JSP, Web frameworks: Elimination html tags from text when posting

  1. Elimination html tags from text when posting (1 messages)

    Friends:
        I'm building a simple forum-like application. I want to parse the text of each post in order to eliminate or eventually replace html tags, so that no html ends up it the generated view of each thread.
        Does anyone know a library, package or algorithm with this funtionality implemented? I'd hate to code it myself.
        Thanks in advance!

    Regards,
    Martin

    Threaded Messages (1)

  2. try a regexp[ Go to top ]

    Maybe not what you want, but I've used a regular expression like this successfully before to remove html/xml code from a string:

    str = str.replaceAll("<[^>]*>", "");