diff --git a/lang/ar_AR.ini b/lang/ar_AR.ini index 7bad38e0..90006d83 100644 --- a/lang/ar_AR.ini +++ b/lang/ar_AR.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/be_BY.ini b/lang/be_BY.ini index 7619234e..dd01bf40 100644 --- a/lang/be_BY.ini +++ b/lang/be_BY.ini @@ -341,3 +341,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/cs_CZ.ini b/lang/cs_CZ.ini index 0efb7edb..f1644639 100644 --- a/lang/cs_CZ.ini +++ b/lang/cs_CZ.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/da_DK.ini b/lang/da_DK.ini index 0f741751..46c6ba42 100644 --- a/lang/da_DK.ini +++ b/lang/da_DK.ini @@ -351,3 +351,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/de_DE.ini b/lang/de_DE.ini index 7c082bb2..c2f3b4b5 100644 --- a/lang/de_DE.ini +++ b/lang/de_DE.ini @@ -340,3 +340,4 @@ subpages = "Unterseiten" getstarted = "Los geht's" onthispage = "Auf dieser Seite" backtotop = "Nach oben" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/de_DE_gender_doppelpunkt.ini b/lang/de_DE_gender_doppelpunkt.ini index 551734ee..f1139a6a 100644 --- a/lang/de_DE_gender_doppelpunkt.ini +++ b/lang/de_DE_gender_doppelpunkt.ini @@ -340,3 +340,4 @@ subpages = "Unterseiten" getstarted = "Los geht's" onthispage = "Auf dieser Seite" backtotop = "Nach oben" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/de_DE_gender_dudenkonform.ini b/lang/de_DE_gender_dudenkonform.ini index 18af8cb1..9f60b167 100644 --- a/lang/de_DE_gender_dudenkonform.ini +++ b/lang/de_DE_gender_dudenkonform.ini @@ -340,3 +340,4 @@ subpages = "Unterseiten" getstarted = "Los geht's" onthispage = "Auf dieser Seite" backtotop = "Nach oben" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/el_GR.ini b/lang/el_GR.ini index 777c38fc..3ac07202 100644 --- a/lang/el_GR.ini +++ b/lang/el_GR.ini @@ -342,3 +342,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/en_US.ini b/lang/en_US.ini index e1c41ae8..d5706d75 100644 --- a/lang/en_US.ini +++ b/lang/en_US.ini @@ -407,3 +407,15 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." +health_check = "Health Check" +directory_permissions = "Directory Permissions" +cache_folder_writable = "/cache/ directory is writable." +content_folder_not_writable = "/content/ directory is not writable, please update the permissions/ownership to continue." +content_folder_writable = "/content/ directory is writable." +users_folder_not_writable = "/config/users/ directory is not writable, please update the permissions/ownership to continue." +users_folder_writable = "/config/users/ directory is writable." +php_check = "PHP Version" +php_version_check_passed = "PHP version meets the minimum requirement." +php_version_check_failed = "PHP version does not meet the minimum requirement. Please upgrade your PHP version." +php_modules = "PHP Modules" diff --git a/lang/eo_EO.ini b/lang/eo_EO.ini index 0eaf827c..2e402852 100644 --- a/lang/eo_EO.ini +++ b/lang/eo_EO.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/es_ES.ini b/lang/es_ES.ini index 5e9dcdc9..8fb6c807 100644 --- a/lang/es_ES.ini +++ b/lang/es_ES.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/fa_IR.ini b/lang/fa_IR.ini index bd573eef..e5e876bc 100644 --- a/lang/fa_IR.ini +++ b/lang/fa_IR.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/fr_FR.ini b/lang/fr_FR.ini index 56e2c49e..4a8e53bc 100644 --- a/lang/fr_FR.ini +++ b/lang/fr_FR.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/gl_ES.ini b/lang/gl_ES.ini index b2867a66..d3d7d931 100644 --- a/lang/gl_ES.ini +++ b/lang/gl_ES.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/gu_GU.ini b/lang/gu_GU.ini index 227c0754..5a96b7f7 100644 --- a/lang/gu_GU.ini +++ b/lang/gu_GU.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/hi_HI.ini b/lang/hi_HI.ini index 4a35a652..ed6c1188 100644 --- a/lang/hi_HI.ini +++ b/lang/hi_HI.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/hr_HR.ini b/lang/hr_HR.ini index 7fe76419..4e919cb2 100644 --- a/lang/hr_HR.ini +++ b/lang/hr_HR.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/hu_HU.ini b/lang/hu_HU.ini index c37f2cc0..fe0427fd 100644 --- a/lang/hu_HU.ini +++ b/lang/hu_HU.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/id_ID.ini b/lang/id_ID.ini index 837f63dd..1f643d0d 100644 --- a/lang/id_ID.ini +++ b/lang/id_ID.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/it_IT.ini b/lang/it_IT.ini index 4c1ff3a7..d9f94071 100644 --- a/lang/it_IT.ini +++ b/lang/it_IT.ini @@ -407,3 +407,4 @@ backtotop = "Torna in cima" subpages = "Sottopagine" getstarted = "Per cominciare" onthispage = "Su questa pagina" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/ko_KO.ini b/lang/ko_KO.ini index f2ce9e42..dcdb98a3 100644 --- a/lang/ko_KO.ini +++ b/lang/ko_KO.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/ku_KU.ini b/lang/ku_KU.ini index 40444a0f..a07833b0 100644 --- a/lang/ku_KU.ini +++ b/lang/ku_KU.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/ms_MY.ini b/lang/ms_MY.ini index da727ae4..4067ac0c 100644 --- a/lang/ms_MY.ini +++ b/lang/ms_MY.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/nl_NL.ini b/lang/nl_NL.ini index 867b4a00..424436ac 100644 --- a/lang/nl_NL.ini +++ b/lang/nl_NL.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/pl_PL.ini b/lang/pl_PL.ini index 38857936..81061d2f 100644 --- a/lang/pl_PL.ini +++ b/lang/pl_PL.ini @@ -341,3 +341,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/pt_BR.ini b/lang/pt_BR.ini index dd34ab7d..19c1c04c 100644 --- a/lang/pt_BR.ini +++ b/lang/pt_BR.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/ru_RU.ini b/lang/ru_RU.ini index f4e07156..39f7626f 100644 --- a/lang/ru_RU.ini +++ b/lang/ru_RU.ini @@ -341,3 +341,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/sv_SE.ini b/lang/sv_SE.ini index 33e2ed8b..d15866f5 100644 --- a/lang/sv_SE.ini +++ b/lang/sv_SE.ini @@ -352,3 +352,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/tr_TR.ini b/lang/tr_TR.ini index 40765140..5e446bbf 100644 --- a/lang/tr_TR.ini +++ b/lang/tr_TR.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/uk_UA.ini b/lang/uk_UA.ini index 908ff05c..44414d6e 100644 --- a/lang/uk_UA.ini +++ b/lang/uk_UA.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/zh_CN.ini b/lang/zh_CN.ini index 7dd4c09a..e063fbf3 100644 --- a/lang/zh_CN.ini +++ b/lang/zh_CN.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/lang/zh_TW.ini b/lang/zh_TW.ini index 670821c1..d674b5c9 100644 --- a/lang/zh_TW.ini +++ b/lang/zh_TW.ini @@ -340,3 +340,4 @@ backtotop = "Back to top" subpages = "Sub pages" getstarted = "Get started" onthispage = "On this page" +cache_folder_not_writable = "/cache/ directory is not writable, please update the permissions/ownership to continue." diff --git a/system/admin/admin.php b/system/admin/admin.php index 1e4a09f5..ce766e14 100644 --- a/system/admin/admin.php +++ b/system/admin/admin.php @@ -1674,6 +1674,7 @@ function toolbar() } if ($role === 'editor' || $role === 'admin') { $toolbar .= '
  • ' . i18n('Clear_cache') . '
  • '; + $toolbar .= '
  • ' . i18n('health_check') . '
  • '; } $toolbar .= '
  • ' . i18n('Edit_profile') . '
  • '; $toolbar .= '
  • ' . i18n('Logout') . '
  • '; diff --git a/system/admin/views/health.html.php b/system/admin/views/health.html.php new file mode 100644 index 00000000..fda25b8c --- /dev/null +++ b/system/admin/views/health.html.php @@ -0,0 +1,70 @@ + +'.i18n('health_check').'
    '; + +echo '

    '.i18n('php_check').'

    '; + +$requiredPhpVersion = '7.2'; +if (version_compare(PHP_VERSION, $requiredPhpVersion, '>=')) { + echo '

    ✅ '.i18n('php_version_check_passed').' (Current: '.PHP_VERSION.', Required: '.$requiredPhpVersion.')

    '; +} else { + echo '

    ❌ '.i18n('php_version_check_failed').' (Current: '.PHP_VERSION.', Required: '.$requiredPhpVersion.')

    '; +} + +echo '

    '.i18n('directory_permissions').'

    '; + +$cachedir = 'cache/'; +if (!is_writable($cachedir)) { + echo '

    ❌ '.i18n('cache_folder_not_writable').'

    '; +} else { + echo '

    ✅ '.i18n('cache_folder_writable').'

    '; +} + +$contentdir = 'content/'; +if (!is_writable($contentdir)) { + echo '

    ❌ '.i18n('content_folder_not_writable').'

    '; +} else { + echo '

    ✅ '.i18n('content_folder_writable').'

    '; +} + +$usersdir = 'config/users/'; +if (!is_writable($usersdir)) { + echo '

    ❌ '.i18n('users_folder_not_writable').'

    '; +} else { + echo '

    ✅ '.i18n('users_folder_writable').'

    '; +} + +echo '

    '.i18n('php_modules').'

    '; + +$requiredChecks = array( + 'json' => extension_loaded('json'), + 'mbstring' => extension_loaded('mbstring'), + 'libxml' => extension_loaded('libxml'), + 'dom' => extension_loaded('dom') && class_exists('DOMDocument'), + 'simplexml' => extension_loaded('simplexml') && class_exists('SimpleXMLElement'), + 'xml' => extension_loaded('xml'), + 'hash' => extension_loaded('hash'), + 'session' => extension_loaded('session'), + 'pcre' => extension_loaded('pcre'), + 'filter' => extension_loaded('filter'), + 'ctype' => extension_loaded('ctype'), + 'openssl' => extension_loaded('openssl'), + 'zip' => extension_loaded('zip') && class_exists('ZipArchive'), + 'gd' => extension_loaded('gd') && function_exists('gd_info'), + 'iconv' => extension_loaded('iconv') && function_exists('iconv'), + 'intl' => extension_loaded('intl'), + 'apcu' => extension_loaded('apcu'), + 'mcrypt' => extension_loaded('mcrypt'), +); + +foreach ($requiredChecks as $label => $ok) { + if ($ok) { + echo '

    ✅ '.$label.'

    '; + } else { + echo '

    ❌ '.$label.'

    '; + } +} + diff --git a/system/admin/views/layout.html.php b/system/admin/views/layout.html.php index 6df46d26..760d4235 100644 --- a/system/admin/views/layout.html.php +++ b/system/admin/views/layout.html.php @@ -262,6 +262,13 @@

    +