fix in installer
This commit is contained in:
parent
9d5fe7cd08
commit
b921662fd8
|
@ -122,7 +122,7 @@ class Filesystem {
|
|||
|
||||
// Delete a file or directory recursive
|
||||
// The directory is delete
|
||||
public static function deleteRecursive($source)
|
||||
public static function deleteRecursive($source, $deleteDirectory=true)
|
||||
{
|
||||
if (!self::directoryExists($source)) {
|
||||
return false;
|
||||
|
@ -138,8 +138,11 @@ class Filesystem {
|
|||
}
|
||||
}
|
||||
|
||||
if ($deleteDirectory) {
|
||||
return rmdir($source);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
// Compress a file or directory
|
||||
// $source = /home/diego/example
|
||||
|
@ -216,7 +219,7 @@ class Filesystem {
|
|||
$number = 0;
|
||||
$tmpName = $filename.'_'.$number.'.'.$fileExtension;
|
||||
while (Sanitize::pathFile($path.$tmpName)) {
|
||||
$number++;
|
||||
$number = $number + 1;
|
||||
$tmpName = $filename.'_'.$number.'.'.$fileExtension;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -96,6 +96,8 @@ class pluginRemoteContent extends Plugin {
|
|||
Filesystem::deleteRecursive(PATH_UPLOADS);
|
||||
mkdir(PATH_PAGES, 0755, true);
|
||||
mkdir(PATH_UPLOADS, 0755, true);
|
||||
mkdir(PATH_UPLOADS_PROFILES, 0755, true);
|
||||
mkdir(PATH_UPLOADS_THUMBNAILS, 0755, true);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
16
install.php
16
install.php
|
@ -591,12 +591,16 @@ if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
|||
<?php
|
||||
$system = checkSystem();
|
||||
if (!empty($system)) {
|
||||
foreach ($system as $values) {
|
||||
echo '<div class="uk-panel">';
|
||||
echo '<div class="uk-panel-badge uk-badge uk-badge-danger">FAIL</div>';
|
||||
echo '<h3 class="uk-panel-title">'.$values['title'].'</h3>';
|
||||
echo $values['errorText'];
|
||||
echo '</div>';
|
||||
foreach ($system as $error) {
|
||||
echo '
|
||||
<table class="table">
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>'.$error.'</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
';
|
||||
}
|
||||
}
|
||||
elseif (isset($_GET['language']))
|
||||
|
|
Loading…
Reference in New Issue