Changeset 37 for system/backup/do-backup.php
- Timestamp:
- Jan 31, 2008, 8:38:47 PM (17 years ago)
- Location:
- system
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
system
-
Property svn:ignore
set to
nohup.out
-
Property svn:ignore
set to
-
system/backup/do-backup.php
r1 r37 1 <? 2 include(' /a/html/db.php');3 DB_Init('localhost','root','','backup');1 <?php 2 include('../html/global.php'); 3 $Database->select_db('backup'); 4 4 5 function mkdirrec($path,$mode) { 5 function mkdirrec($path,$mode) 6 { 6 7 if (!is_dir($path)) { 7 8 if (!@mkdir($path,$mode)) { … … 16 17 // Nacti polozky z databaze 17 18 $Rows = array(); 18 DB_Query("SELECT * FROM items WHERE parent=0");19 while($Row = DB_Row()) array_push($Rows,$Row);19 $DbResult = $Database->query("SELECT * FROM items WHERE parent=0"); 20 while($Row = $DbResult->fetch_array()) array_push($Rows,$Row); 20 21 21 22 while ($Row = array_shift($Rows)) { 22 23 if ($Row['description']) echo('Zalohuji '.$Row['description']."\n"); 23 24 // Nacteni vyjimek 24 DB_Query("SELECT * FROM items WHERE parent=".$Row['id']);25 $DbResult = $Database->query("SELECT * FROM items WHERE parent=".$Row['id']); 25 26 $Exceptions = array(); 26 while($Except = DB_Row()) $Exceptions[$Except['name']] = 1;27 while($Except = $DbResult->fetch_array()) $Exceptions[$Except['name']] = 1; 27 28 // Prochazeni slozek 28 29 $root = $Row['name'];
Note:
See TracChangeset
for help on using the changeset viewer.