Simple php function to get and display source code of a webpage.
function getSourceCode($pageurl) {
$lines = file($pageurl);
$output = "";
foreach ($lines as $line_num => $line) {
// loop thru each line and prepend line numbers
$output.= "Line #<b>{$line_num}</b> : " . htmlspecialchars($line) . "<br>\n";
}
}
function getSourceCode($pageurl) {
$lines = file($pageurl);
$output = "";
foreach ($lines as $line_num => $line) {
// loop thru each line and prepend line numbers
$output.= "Line #<b>{$line_num}</b> : " . htmlspecialchars($line) . "<br>\n";
}
}