這是我有文字:正則表達式來刪除 「= R」
[ '
"message": "WorldStage Supports Massive 4K Video Mapping at Adobe MAX=\r
with Christie Boxer 4K Projectors',
'
"message": "Inside Track: Trading Focus on Shares of Adobe Systems In=\r
c. (ADBE)' ]
我希望它看起來像:
[ '
"message": "WorldStage Supports Massive 4K Video Mapping at Adobe with Christie Boxer 4K Projectors',
'
"message": "Inside Track: Trading Focus on Shares of Adobe Systems Inc. (ADBE)' ]
正則表達式我想:
texts[i].replace(/=\\r/g, "")
但它不工作。可以在StackOverflow中找到類似的問題。 :(
它是一個2 char('''''和'r')組合還是一個CR?嘗試'.replace(/ = \ r/g,「」)' –
似乎有效,但它仍然是下一行。我想要它在同一行。 –
然後還有其他換行符號。試試'.replace(/ = [\ r \ n] +/g,「」)' –