Java HTML Clean cleanHtml(String html)

Here you can find the source of cleanHtml(String html)

Description

clean Html

License

Open Source License

Declaration

public static String cleanHtml(String html) 

Method Source Code

//package com.java2s;

public class Main {
    public static String cleanHtml(String html) {
        return html.replaceAll("<style[^>]*?>[\\s\\S]*?</style>|<script[^>]*?>[\\s\\S]*?</script>|<.+?>", "");
    }/*  ww w  . ja va 2 s.c o m*/
}

Related

  1. cleanHTML(String input)
  2. cleanHTML(String s)
  3. cleanHtml(String s)
  4. cleanHtml(String str)