Answer Posted / rameshmjs
nl2br — Inserts HTML line breaks before all newlines in a string
Example using nl2br()
<?php
echo nl2br("foo isn't\n bar");
?>
The above example will output:
foo isn't<br />
bar
| Is This Answer Correct ? | 6 Yes | 0 No |
Post New Answer View All Answers
How to check whether a number is prime or not?
What is data structure in php?
What are the rules in creating php variable?
How failures in execution are handled with include() and require() functions?
What are the method available in form submitting?
How to get no. of rows using MYSQL function?
What is final class and final method in php?
Which function is used to strip whitespace?
How is php different from other languages?
How easy is php?
What is the function of trim?
How many data types are used by php?
How does the identity operator === compare two values?
What does == mean in php?
Can php replace javascript?