[go: up one dir, main page]

Menu

[r1]: / www / dbkup.php  Maximize  Restore  History

Download this file

130 lines (114 with data), 4.5 kB

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!--
VMLMAT: VM Linux Management and Archival Tool.
Copyright (c) 2007, Ronnie Michael, BMC Software Inc.
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
* Neither the name of the BMC Software Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-->
<html><head><title>VMLMAT VM Linux Management and Archival Tool</title>
<link rel="stylesheet" type="text/css" href="/templates/astyle.css" title="standard"/>
</head><body>
<div id="banner"><h1><a href="/sbkupu.php">VMLMAT</a></h1><h2>Linux Management System</h2></div>
<div id="leftcontent">
<p> Please Select one </p>
</div>
<div id="centercontent">
<div class="floatright"> <!-- standard --> <a href="sbkup.php" >START A BACKUP</a> |<a href="dbkup.php" >DELETE A BACKUP</a> | <a href='helpd.php' 'popuplink', 'width=640,height=480,directories=no,location=no,scrollbars=yes,menubar=no,status=yes,toolbar=no,resizable=yes'); return false"title="" target="_self">Help</a></div>
<?
function directory($result,$usr) {
$result="";
$nl = "\n";
$files=array();
$pusr=$usr . "/.";
$path=$usr . "/";
$handle=opendir($pusr);
$i=0;
while ($file = readdir($handle)) {
if ($file == "." || $file == "..") { } else {
$sln=strlen($file);
$name=substr($file,0,$sln-4);
$files[]="<input type=submit name=d" . $i . ' value=' . $file . ' style="border: 1px inset black;"> </br>' . $nl;
$i++;
}
}
closedir($handle);
array_multisort($files);
$t=count($files);
$i=0;
print "<input type=hidden name=count value=" . $t . '>' . $nl;
while ($t > $i){
print "$files[$i]";
$i++;
}
return $result;
}
?>
<?
/* if they bookmark this throw them out if not already validated through auth.php */
session_start();
$user=$_SESSION['user'];
$usr=$_SESSION['dir'];
if (empty($user)){
#issue error message
$_SESSION['errmsg']="autherr";
session_write_close();
header("Location: http://".$_SERVER['HTTP_HOST']."/errmsg.php");
exit;
}
if (isset($_REQUEST['cancel'])) {
#issue error message
$_SESSION['errmsg']="cancel";
session_write_close();
header("Location: http://".$_SERVER['HTTP_HOST']."/errmsg.php");
exit;
}
if (empty($usr)) {
#issue error message
$_SESSION['errmsg']="nouser";
session_write_close();
header("Location: http://".$_SERVER['HTTP_HOST']."/errmsg.php");
exit;
}
$result="";
$nl = "\n";
echo "<p><b>$usr directory </b><p>";
echo "<p><b> Select the backup you want to delete </b><p>";
echo '<a name="#comments"></a><a name="#bottom"></a><form method="post" action="../submitd.php"
name="form" >' . $nl;
echo directory($result,$usr);
echo '<p></p>';
echo '<input type="submit" name="cancel" value="Cancel" style="border: 1px inset black;">' . $nl;
echo "<input type=hidden name=dir value=" . $usr . '>' . $nl;
?>
</div>
<div id="rightcontent">
<?
print "<p><b>Support links</b><br />";
$rfile = "rlinks.txt";
$fh = fopen($rfile, 'r');
if ($fh) {
while (!feof($fh)) {
$strdata = fgets($fh);
print "$strdata";
}
fclose($fh);
}
print "</p>";
?>
</div>
</body>
</html>