Skip to content

Commit

Permalink
еще
Browse files Browse the repository at this point in the history
  • Loading branch information
musicman3 committed Jan 21, 2021
1 parent de97d54 commit ce318e6
Show file tree
Hide file tree
Showing 10 changed files with 16 additions and 16 deletions.
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/.htaccess

/model/storage/logs/errors.log
/storage/logs/errors.log

/model/storage/configure/configure.php
/storage/configure/configure.php
/uploads/
/model/nbproject/private/
/nbproject/private/
Expand Down
2 changes: 1 addition & 1 deletion language/english/install/english.lng
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ database_port = Port
database_prefix = DB Prefix
database_type = DB Type
email_check = Please, enter correct E-Mail
file_configure_not_found = File model/storage/configure/configure.php not found!
file_configure_not_found = File storage/configure/configure.php not found!
file_not_found = SQL-file in model/databases/ not found!
hash_method = Hashing Method
install_button = INSTALL
Expand Down
2 changes: 1 addition & 1 deletion language/russian/install/russian.lng
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ database_port = Порт базы данных
database_prefix = Префикс базы данных
database_type = Тип БД
email_check = Пожалуйста, введите корректный E-Mail
file_configure_not_found = Файл конфигурации model/storage/configure/configure.php не доступен!
file_configure_not_found = Файл конфигурации storage/configure/configure.php не доступен!
file_not_found = SQL-файл базы данных в model/databases/ не доступен!
hash_method = Метод хэширования
install_button = УСТАНОВИТЬ
Expand Down
8 changes: 4 additions & 4 deletions model/eMarket/Admin/ErrorLog.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ public static function menu() {
*
*/
public function delete() {
if (Valid::inPOST('delete') == 'delete' && file_exists(ROOT . '/model/storage/logs/errors.log')) {
unlink(ROOT . '/model/storage/logs/errors.log');
if (Valid::inPOST('delete') == 'delete' && file_exists(ROOT . '/storage/logs/errors.log')) {
unlink(ROOT . '/storage/logs/errors.log');

Messages::alert('success', lang('action_completed_successfully'));
}
Expand All @@ -58,8 +58,8 @@ public function delete() {
*
*/
public function data() {
if (file_exists(ROOT . '/model/storage/logs/errors.log')) {
$lines = array_reverse(file(ROOT . '/model/storage/logs/errors.log'));
if (file_exists(ROOT . '/storage/logs/errors.log')) {
$lines = array_reverse(file(ROOT . '/storage/logs/errors.log'));
} else {
$lines = [];
}
Expand Down
10 changes: 5 additions & 5 deletions model/eMarket/Install/Success.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,20 +98,20 @@ public function config() {
*
*/
public function save() {
$fpd = fopen(self::$root . '/model/storage/configure/configure.php', 'w+');
$fpd = fopen(self::$root . '/storage/configure/configure.php', 'w+');
fputs($fpd, self::$config);
fclose($fpd);

if (file_exists(self::$root . '/model/storage/configure/configure.php')) {
chmod(self::$root . '/model/storage/configure/configure.php', 0644);
if (file_exists(self::$root . '/storage/configure/configure.php')) {
chmod(self::$root . '/storage/configure/configure.php', 0644);
} else {
header('Location: /controller/install/error.php?file_configure_not_found=true');
}

require_once(self::$root . '/model/storage/configure/configure.php');
require_once(self::$root . '/storage/configure/configure.php');

if (self::$db_type == 'mysql') {
$file_name = ROOT . '/model/storage/databases/mysql.sql';
$file_name = ROOT . '/storage/databases/mysql.sql';
}

if (!file_exists($file_name)) {
Expand Down
4 changes: 2 additions & 2 deletions model/start.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
$TIME_START = microtime(1);
//ENABLE LOG
error_reporting(-1);
ini_set('error_log', __DIR__ . '/storage/logs/errors.log');
ini_set('error_log', getenv('DOCUMENT_ROOT') . '/storage/logs/errors.log');

//AUTOLOAD FOR CLASSES
require_once('vendor/autoload.php');
Expand Down Expand Up @@ -36,7 +36,7 @@

// Config file and etc.
if (Settings::path() == 'admin' OR Settings::path() == 'catalog') {
require_once('storage/configure/configure.php');
require_once(getenv('DOCUMENT_ROOT') . '/storage/configure/configure.php');
}
//Autorize
Autorize::init();
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion view/default/admin/pages/error_log/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<?php echo Settings::titlePageGenerator() ?>
</h3>
</div>
<?php if (file_exists(ROOT . '/model/storage/logs/errors.log') == true) { ?>
<?php if (file_exists(ROOT . '/storage/logs/errors.log') == true) { ?>
<div class="panel-body">

<div class="table-responsive">
Expand Down

0 comments on commit ce318e6

Please sign in to comment.