Revision 726
Added by thorn over 16 years ago
upgrade-script.php | ||
---|---|---|
398 | 398 |
list($files, $dirs) = list_files_dirs($dir.'/'.$file, $depth, $files, $dirs); |
399 | 399 |
} |
400 | 400 |
} else { |
401 |
$files[] = $dir.'/'.$file; |
|
401 |
$newfile = $dir.'/'.$file; |
|
402 |
if(filesize($newfile) <= 100) |
|
403 |
$files[] = $newfile; |
|
402 | 404 |
} |
403 | 405 |
} |
404 | 406 |
closedir($dh); |
405 |
natcasesort($files); |
|
406 |
natcasesort($dirs); |
|
407 | 407 |
return(array($files, $dirs)); |
408 | 408 |
} |
409 | 409 |
list($files, $dirs) = list_files_dirs(WB_PATH.PAGES_DIRECTORY); |
... | ... | |
489 | 489 |
} |
490 | 490 |
// check if we need to create a subdir somewhere |
491 | 491 |
$dirs = array(); |
492 |
while(dirname($link) != '/') { |
|
492 |
while(dirname($link) != '/' && dirname($link) != '.') {
|
|
493 | 493 |
$link = dirname($link); |
494 | 494 |
$dirs[] = WB_PATH.PAGES_DIRECTORY.$link; |
495 | 495 |
} |
496 | 496 |
foreach(array_reverse($dirs) as $dir) { |
497 | 497 |
if(!file_exists($dir)) { |
498 |
mkdir($dir, OCTAL_DIR_MODE); |
|
498 |
@mkdir($dir, OCTAL_DIR_MODE);
|
|
499 | 499 |
} |
500 | 500 |
} |
501 | 501 |
// create new file in pages/ |
Also available in: Unified diff
issue with menulink in upgrade-script. Fixed?