Source Viewers
|
|
|
|
<?
/*
-=- Source function -=-
Gemaakt door: Ivo Koster
Gemaakt op: 06-07-2000
Laast bijgewerkt op: 06-07-2000
Versie: 0.1
(C)2000 Ivo Koster, Exed.
*/
function source($source)
{
clearstatcache(); // cache of the filething dele.
if(!file_exists($source)) // Checking for the file $source.
{
return 1;
}
$src =fopen($source,"r");
$test = fread ($src, filesize($source)); // Read the file
$test = htmlentities($test); // make all the html entry's work
$test = str_replace(" "," ",$test); // make the " " to
$test = nl2br($test); // make the /n to <BR>
echo $test; // test it out
fclose($src);
return 0;
}
source($source); ?>
|
|
|
Usage Example
|
source.php3?source=../test.php
source.php3?source=../test.html
source.php3?source=../test.shtml
or use it in as a funtion
|
|
|
Rate This Script
|
|
|
|