Notepad++ Replace new line inside text

后端 未结 3 853
暗喜
暗喜 2021-01-14 08:44

I have this sample, because is one of one million rows with that. I have this text:




        
3条回答
  •  暗喜
    暗喜 (楼主)
    2021-01-14 09:01

    If you can't make jmstoker's solution work, try like this:

    • you need to check if the line breaks are just CRLF or just one of them, for that, click on the toolbar the icon "show all characters" or go to menu View -> Show Symbol -> Show all characters
    • in the replace dialog select the "Extended" search mode
    • in the "find what:" field, write this: \r\n (or just \r or just \n, basically match CR with \r and LF with \n)
    • leave the replace with field empty
    • once this is done, all the line breaks will have been replaced, but you want the to be on its own line, so just replace still using an extended search with \r\n

    I'm guessing you also have rows with class "odd" or something like that so you might need to repeat that last step with the different class :)

提交回复
热议问题