Java HTML Encode HTMLBREncode(String str)

Here you can find the source of HTMLBREncode(String str)

Description

HTMLBR Encode

License

Open Source License

Declaration

public static String HTMLBREncode(String str) 

Method Source Code

//package com.java2s;
//License from project: GNU General Public License 

public class Main {
    public static String HTMLBREncode(String str) {
        return str.replaceAll("\r\n", "\r\n<br class=\"br\"/>\r\n");
    }//from  w  ww .  j av  a2 s.  c  o m
}

Related

  1. forHTMLTag(String aTagFragment)
  2. forHTMLTag(String aTagFragment)
  3. html(String text)
  4. html(String text)
  5. html_encode(String input_string)
  6. htmlEncode(final String source, StringBuffer target)
  7. htmlEncode(Object input)
  8. htmlEncode(String html)
  9. htmlEncode(String html)