1<?php
2echo "If you view the page source \r\n you will find a newline in this string.";
3echo "<br>";
4echo nl2br("You will find the \n newlines in this string \r\n on the browser window.");
5?>
6 // 2 Way
7 <?php echo $clientid, ' ', $lastname, PHP_EOL;?>
1<?php
2echo "Hello world this is example \r\n in php.";
3echo "<br>";
4echo nl2br("You will find the \n newlines in this string \r\n on the browser window.");
5?>
1//let a variable contain multiple line
2//add <br> tag in string
3$variable = "123 <br> ";