Answer Posted / ram
The nl2br() function inserts HTML line breaks (<br />) in
front of each newline (\n) in a string
Syntax: nl2br(string)
<?php
echo nl2br("One line.\nAnother line.");
?>
output: One line.
Another line.
| Is This Answer Correct ? | 11 Yes | 1 No |
Post New Answer View All Answers
How to redirect https to http url through .htaccess?
What is input sanitization in php?
How to display your correct URL of the current web page?
Do you know what are traits?
What are the advantages and disadvantages of cascade style sheets?
How to access a Static Member of a Class in PHP?
What are major variables in research?
What is the difference between rest and soap?
Why and where do we use htaccess?
What are the ways to include file in php?
What is mvc in php?
What is the method to execute a php script from the command line?
How do you destroy a session?
What is php and how do you use it?
What are the disadvantages of php?