Try \r\n
in place of \n
The difference between \n and \r\n
It should be noted that this is applicable to line returns in emails. For other scenarios, please refer to rokjarc’s answer.
More Related Contents:
- Pass a PHP string to a JavaScript variable (and escape newlines) [duplicate]
- How to replace different newline styles in PHP the smartest way?
- Writing a new line to file in PHP (line feed)
- PHP Echo Line Breaks
- PHP Regex: How to match \r and \n without using [\r\n]?
- New lines (\r\n) are not working in email body
- fputcsv and newline codes
- Pass a PHP variable to a JavaScript variable
- PHP: trying to create a new line with “\n”
- How to replace all XHTML/HTML line breaks () with new lines?
- remove new line characters from txt file using php
- How to handle newlines in Javascript? (from PHP)
- PHP Linefeeds (\n) Not Working
- How to Update one column (point) in php sql [duplicate]
- How Can I add HTML And CSS Into PDF [closed]
- Getting checkbox values on submit
- Does $_SERVER[‘HTTP_X_REQUESTED_WITH’] exist in PHP or not?
- Laravel blank white screen
- Is there any way to detect strings like putjbtghguhjjjanika?
- Converting HTML to PDF using PHP? [duplicate]
- mysql_fetch_array() expects parameter 1 to be resource problem [duplicate]
- Turn database result into array
- How to use single quote inside an echo which is using single quote
- PHP php_network_getaddresses: getaddrinfo failed: No such host is known
- Calculate an IPv6 range from a CIDR prefix?
- PHP cURL: CURLOPT_CONNECTTIMEOUT vs CURLOPT_TIMEOUT
- html5 display as image rather than “choose file” button
- json_encode not working with a html string as value
- Xdebug ignores breakpoints
- How to pass variables between php scripts?