---
title: "android 替换 \\n\\r"
author: "sinykk"
date: "2014-02-07T22:58:37Z"
tags: []
categories: ["移动开发"]
slug: "android-n-r"
draft: false
lastmod: "2014-02-07T22:58:37Z"
id: 2012207
url: "https://sinykk.iteye.com/blog/2012207"
---

[http://www.crifan.com/android\_java\_string\_regex\_replace\_remove\_slash\_in\_multiple\_define\_line\_end/](http://www.crifan.com/android_java_string_regex_replace_remove_slash_in_multiple_define_line_end/)

 

str = str.replaceAll("[\\\\\\\\n]()", "&lt;br/&gt;");