Файл: chmod.php
Строк: 25
<?php
if (isset($_POST['submit'])) {
require_once('chmod.class.php');
if (!empty($_POST['path'])) {
$chmod = new fileSettings($_POST['path'], $_POST['chmod']);
$log = $chmod->getLog();
}
else {
$error[0][] = 'Path or chmod value is not set';
}
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chmod settings</title>
</head>
<body>
<h1>CHMOD Administrator</h1>
<br />
<form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post">
<p>
<label>Path:</label> <input name="path" type="text" size="50" value="<?php echo $_SERVER['DOCUMENT_ROOT']; ?>" /><br />
<!--<label>CHMOD:</label> <input name="chmod" type="text" size="10" maxlength="4" value="" /> <span>(0755)</span><br />-->
<input name="reset" type="reset" value="Reset" /> <input name="submit" type="submit" value="Set CHMOD" />
</p>
</form>
<br /><br />
<?php
if (!empty($log)) {
?>
<h2>Loggging:</h2>
<?php
foreach ($log as $res) {
?>
<p><?php echo $res; ?></p>
<?php
}
}
?>
</body>
</html>