search
LoginSignup
94
Help us understand the problem. What are the problem?

More than 5 years have passed since last update.

posted at

updated at

【PHP】PHP_EOL

PHP_EOLは改行を表していて、環境によって自動で改行コードを切り替えてくれる。

OS 改行コード 改行コード文字
Windows CRLF \r\n
Linux,Unix,MACOS10 LF \n
使い方例
echo 'こんにちわ',PHP_EOL;

関係ないけど、echo って「,」区切りで複数出力できるらしい。

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
What you can do with signing up
94
Help us understand the problem. What are the problem?