Begin text on new line php
A simple one!
To start a new line in PHP, you can use the PHP_EOL constant, which represents the end of a line (either \n
or \r\n
depending on the operating system).
Here's an example:
echo "Hello, world!". PHP_EOL;
This will output:
Hello, world!
Alternatively, you can use the \n
character to start a new line:
echo "Hello, world!\n";
This will also output:
Hello, world!
Note that the \n
character is platform-independent, meaning it will work on both Windows and Unix-based systems.