DirReadout v1.0
Auteur: IceCold - 09 januari 2005 - 18:04 - Gekeurd door: Dennisvb - Hits: 7181 - Aantal punten: 1.40 (5 stemmen)
Uitleg staat in readme
|
Code: |
####################################################
### Dir Readout ###
####################################################
## By Ice-Cold #####################################
####################################################
# Dir Readout v1.0 #
# #
# Installatie #
# #
# Zet de PHP file in de folder die je wil #
# printen. Hij zal alle foto's tussen #
# [img][/img] tags zetten,de meest gebruikte #
# image tag vorm... Gewoon uploaden en naar #
# de file gaat. Er zit zelfs een rapport in #
####################################################
# #
# Contacteer mij voor.. #
# #
# problemen, en als je het gebruikt, maar #
# ook bewerkt, zou ik graag zien wat je net #
# gedaan hebt, kan ik mss ook iets uit leren #
####################################################
####################################################
################### Have Fun #######################
####################################################
<html>
<head>
<title>Dir Readout | by Ice-Cold</title>
</head>
<body>
<?php
$file = explode("/", $_SERVER['PHP_SELF']);
$count = count($file);
$file = $file[$count -1];
$uitkomst = strlen($file);
$buitkomst = strlen($_SERVER['PHP_SELF']);
$tral = $buitkomst - $uitkomst;
$volledig_voor = $_SERVER['HTTP_HOST'];
$volledig_na = substr($_SERVER['PHP_SELF'], 0, $tral);
$aantal_dirs = 0;
$aantal_files = 0;
$aantal_upfiles = 0;
if(function_exists(exif_imagetype)) {
function is_image($a){
if(exif_imagetype($a) == IMAGETYPE_GIF OR exif_imagetype($a) == IMAGETYPE_JPEG OR exif_imagetype($a) == IMAGETYPE_PNG) {
return true;
}
else
{
return false;
}
}
}
else
{
function is_image($a) {
$ext = substr($a, -3);
if($ext == "jpg" OR $ext == "gif" OR $ext == "JPG" OR $ext == "GIF" OR $ext == "png" OR $ext == "PNG") {
return true;
}
else
{
return false;
}
}
}
echo "<center><h1>Dir readout with [IMG][/IMG]</h1><sup>Engine Created by Ice-Cold</sup></center><br>";
if ($handle = opendir('.')) {
while (false !== ($file = readdir($handle))) {
if(substr($file,0,1)!="."){
if(is_dir($file)) {
echo "";
$aantal_dirs = $aantal_dirs + 1;
}
else
{
if(is_image($file) == true) {
echo "[img]";
echo $volledig_voor;
echo $volledig_na;
echo $file;
echo "[/img]<br>";
$aantal_files = $aantal_files + 1;
}
else
{
echo "";
$aantal_upfiles = $aantal_upfiles + 1;
}
}
}
else
{
echo "";
}
}
closedir($handle);
}
?>
<br><br><br>
<b>PHP Script Rapport</b><br><br>
<b>Aantal Directories</b>: <?=$aantal_dirs; ?><br>
<b>Aantal Files Parsed</b>: <?=$aantal_files; ?><br>
<b>Aantal Files Niet Geparsed</b>: <?=$aantal_upfiles; ?><br>
<b>Aantal Files In Totaal</b>: <?=$aantal_upfiles + $aantal_files; ?><br>
</body>
</html>
<html> <head> <title>Dir Readout | by Ice-Cold</title> </head> <body> <?php $file = explode("/", $_SERVER['PHP_SELF']); $file = $file[$count -1]; $buitkomst = strlen($_SERVER['PHP_SELF']); $tral = $buitkomst - $uitkomst; $volledig_voor = $_SERVER['HTTP_HOST']; $volledig_na = substr($_SERVER['PHP_SELF'], 0, $tral); $aantal_dirs = 0; $aantal_files = 0; $aantal_upfiles = 0; function is_image($a){ return true; } else { return false; } } } else { function is_image($a) { if($ext == "jpg" OR $ext == "gif" OR $ext == "JPG" OR $ext == "GIF" OR $ext == "png" OR $ext == "PNG") { return true; } else { return false; } } } echo "<center><h1>Dir readout with [IMG][/IMG]</h1><sup>Engine Created by Ice-Cold</sup></center><br>"; while (false !== ($file = readdir($handle))) { $aantal_dirs = $aantal_dirs + 1; } else { if(is_image($file) == true) { $aantal_files = $aantal_files + 1; } else { $aantal_upfiles = $aantal_upfiles + 1; } } } else { } } } ?> <br><br><br> <b>PHP Script Rapport</b><br><br> <b>Aantal Directories</b>: <?=$aantal_dirs; ?><br> <b>Aantal Files Parsed</b>: <?=$aantal_files; ?><br> <b>Aantal Files Niet Geparsed</b>: <?=$aantal_upfiles; ?><br> <b>Aantal Files In Totaal</b>: <?=$aantal_upfiles + $aantal_files; ?><br> </body> </html>
Download code (.txt)
|
 |
|
Stemmen |
Niet ingelogd. |
|