The PHP readfile() function reads a file and writes it to the output buffer.
Output
// reads the content of the file
Syntax
readfile(file, include_path, context)
Parameters
Parameter | Description |
---|---|
file | Specifies the file to read (required) |
include_path | Set this parameter to TRUE if you want to search for the file in the include_path (in php.ini) as well |
context | Specifies the context of the file handle; context is a set of options that can modify the behavior of a stream |