Php space, line feed, skip usage instructions. For more information, see. First, let's talk about \ n, \ r, \ t
\ N soft carriage return:
In Windows, line breaks are displayed and returned to the beginning of the next line.
In Linux and unix, it only indicates line breaks, but does not return to the starting position of the next line.
\ R soft space:
In Linux and unix, return to the starting position of the row.
In Mac OS, line breaks are displayed and returned to the start position of the next line, which is equivalent to \ n in Windows.
\ T hop (move to the next column)
Notes:
They are valid in double quotes or delimiters, and are invalid in single quotes.
\ R \ n is generally used together to represent the carriage return key (in Linux and Unix) on the keyboard. \ n (in Windwos) can also be used only, and \ r is used to represent the carriage return in Mac OS!
\ T indicates the "TAB" key on the keyboard.
Line Feed characters in the file:
Windows: \ n
Linux, unix: \ r \ n
Mac OS:
The code is as follows:
$ Dir = "E:/PHPworkspace ";
If ($ handle = opendir ($ dir )){
Echo "directory path: $ dir/n ";
Echo "included files:/n ";
}
// This is the correct way to traverse the Directory
While (false! ==( $ File = readdir ($ handle ))){
Echo "$ file/n ";
}
?>
The code is as follows:
$ Dir = "E:/PHPworkspace ";
If ($ handle = opendir ($ dir )){
Echo "directory path: $ dir/n ";
Echo "included files:/n ";
}
// This is the correct way to traverse the Directory
While (false! ==( $ File = readdir ($ handle ))){
Echo "$ file/n ";
}
?>