update v1.0.7.7
This commit is contained in:
@@ -91,21 +91,18 @@ function php_config_value_to_bytes($val) {
|
||||
*
|
||||
*/
|
||||
function checkFilePermission(&$results) {
|
||||
// $path1 = base_path().DIRECTORY_SEPARATOR.'.env';
|
||||
// // $path2 = base_path().DIRECTORY_SEPARATOR.'config'.DIRECTORY_SEPARATOR.'database.php';
|
||||
// // $path3 = base_path().DIRECTORY_SEPARATOR.'app'.DIRECTORY_SEPARATOR.'Http'.DIRECTORY_SEPARATOR.'routes.php';
|
||||
// // $path4 = base_path().DIRECTORY_SEPARATOR.'config'.DIRECTORY_SEPARATOR.'lfm.php';
|
||||
// $f1 = substr(sprintf("%o",fileperms($path1)),-3);
|
||||
// // $f2 = substr(sprintf("%o",fileperms($path2)),-3);
|
||||
// // $f3 = substr(sprintf("%o",fileperms($path3)),-3);
|
||||
// // $f4 = substr(sprintf("%o",fileperms($path4)),-3);
|
||||
// if( $f1 >= '644') {
|
||||
// $results[] = new TestResult('File permission looks fine', STATUS_OK);
|
||||
return true;
|
||||
// } else {
|
||||
// $results[] = new TestResult('File permissions needed.<ul><b>Change file permission to "644" for following files</b><li>'.$path1.'</li></ul></br>Change the permission manually on your server or <a href="change-file-permission">click here.</a>', STATUS_ERROR);
|
||||
// return false;
|
||||
// }
|
||||
if (file_exists(base_path() . DIRECTORY_SEPARATOR . "example.env")) {
|
||||
$path1 = base_path().DIRECTORY_SEPARATOR.'example.env';
|
||||
$f1 = substr(sprintf("%o",fileperms($path1)),-3);
|
||||
if( $f1 >= '644') {
|
||||
$results[] = new TestResult('File permission looks fine', STATUS_OK);
|
||||
return true;
|
||||
} else {
|
||||
$results[] = new TestResult('File permissions needed.<ul><b>Change file permission to "644" for following files</b><li>'.$path1.'</li></ul></br>Change the permission manually on your server or <a href="change-file-permission">click here.</a>', STATUS_ERROR);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -17,14 +17,15 @@ active
|
||||
<h1 style="text-align: center;">Database Setup</h1>
|
||||
<p class="wc-setup-content">Below you should enter your database connection details. If you’re not sure about these, contact your host.</p>
|
||||
|
||||
@if(Session::has('fails'))
|
||||
@if(Cache::has('fails'))
|
||||
<div class="wc-setup-content">
|
||||
<div class="woocommerce-message woocommerce-tracker">
|
||||
<div class="fail">
|
||||
<span id="fail">{!! Lang::get('lang.fails') !!}! {{Session::get('fails')}}</span><br/><br/>
|
||||
<span id="fail">{!! Lang::get('lang.fails') !!}! {{Cache::get('fails')}}</span><br/><br/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php Cache::forget('fails')?>
|
||||
@endif
|
||||
|
||||
@if($errors->has('default') || $errors->has('host') || $errors->has('port') || $errors->has('databasename') || $errors->has('username') || $errors->has('password'))
|
||||
|
Reference in New Issue
Block a user