$file_contents = readFile("file.txt"); echo $file_contents;
$context = stream_context_create([ 'http' => [ 'method' => 'GET', 'header' => 'Content-type: application/x-www-form-urlencoded', 'user_agent' => 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:77.0) Gecko/20190101 Firefox/77.0' ] ]); $file_contents = readFile("file.txt", false, $context); echo $file_contents;Package library: This function belongs to the PHP Filesystem Extension.