Codice PHP:
<?php
if(isset($_GET["setta"]) && isset($_GET["f"])) {
chmod(htmlentities(ltrim(rtrim($_GET["f"]))),
htmlentities(ltrim(rtrim($_GET["setta"]))));
echo "Impostati il chmod a
".htmlentities(ltrim(rtrim($_GET["setta"])))." al file
".htmlentities(ltrim(rtrim($_GET["f"])));
echo "<br /><br />";
}
if(isset($_GET["d"])) {
$vr = ltrim(rtrim(htmlentities(@$_GET["d"])))."/";
echo "<a href=\"#\" onclick=\"javascript:history.back(); return
false;\"><- Return back</a><br /><br />";
} else {
$vr = "";
}
foreach(glob($vr."*") as $var) {
if(is_dir($var."/")) {
echo "<a href=\"?d={$var}\">{$var}</a>";
echo "<br />";
} else {
echo "<a href=\"{$var}\">{$var}</a> # ";
echo "<a href=\"?setta=0600&f={$var}\">0600</a> - ";
echo "<a href=\"?setta=0644&f={$var}\">0644</a> - ";
echo "<a href=\"?setta=0775&f={$var}\">0775</a> - ";
echo "<a href=\"?setta=0750&f={$var}\">0750</a>";
echo "<br />";
}
}
?>
x il form di upload vedi nella sez how-to...ciao