$line) { echo "Linha #{$line_num} : " . htmlspecialchars($line) . "
\n"; } // Outro exemplo, onde obtemos a página web inteira como uma string. Veja também file_get_contents(). $html = implode ('', file ('http://www.exemplo.com/')); ?>