diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 52591c673..0a2bf0a98 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -35,7 +35,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version: "20" + node-version: "24" cache: "npm" cache-dependency-path: editor/package-lock.json @@ -56,7 +56,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version: "20" + node-version: "24" cache: "npm" cache-dependency-path: package-lock.json diff --git a/.htaccess b/.htaccess index 875df67f4..1976ac7b0 100644 --- a/.htaccess +++ b/.htaccess @@ -55,7 +55,7 @@ RewriteRule ^ - [R=404,L] # If you have folders or files inside berta's folder you wish to access directly, # then modify and uncomment the following line # RewriteCond %{REQUEST_URI} ^/(my_folder_name1|my_folder_name1|my_file.html).*$ [OR] -RewriteCond %{REQUEST_URI} ^/(.well-known|_plugin_shop|engine|INSTALL|storage|_templates|_themes).*$ [OR] +RewriteCond %{REQUEST_URI} ^/(.well-known|_plugin_shop|engine|storage|_templates|_themes).*$ [OR] RewriteCond %{REQUEST_URI} ^/(index\.php|sitemap\.xml\.php|robots\.txt|crossdomain\.xml|favicon\.ico).*$ RewriteRule .* - [L] diff --git a/INSTALL/includes/check.php b/INSTALL/includes/check.php deleted file mode 100644 index 4e3a5fe1a..000000000 --- a/INSTALL/includes/check.php +++ /dev/null @@ -1,172 +0,0 @@ -
Is your website hosted on a suitable server?
'; - - // php version ... - $isOk = version_compare(PHP_VERSION, '8.4', '>='); - $listOk &= $isOk; - $listHasErrors |= ! $isOk; - $testOutput .= getStatus($isOk, 'Supported PHP version', 'Berta needs PHP >= 8.4 support on server. Ask your server administrator to enable supported PHP version.'); - - // multibyte ... - $isOk = function_exists('mb_ereg_replace') && function_exists('mb_strlen') && function_exists('mb_substr'); - $listOk &= $isOk; - $listHasErrors |= ! $isOk; - $testOutput .= getStatus($isOk, 'Server supports international characters', 'Berta cannot function properly without unicode text support. Please ask your server administrator for PHP Multibyte support.'); - - // GD ... - $gdInfo = function_exists('gd_info') ? gd_info() : false; - $isOk = (bool) $gdInfo; - $listOk &= $isOk; - $listHasErrors |= ! $isOk; - $testOutput .= getStatus($isOk, 'PHP Graphics library installed', 'Berta won\'t be able to resize and make thumbnails for images you will upload. Ask your server administrator for PHP GD support.'); - - // GD formats ... - if ($gdInfo) { - $gdInfo['JPEG Support'] = isset($gdInfo['JPEG Support']) ? $gdInfo['JPEG Support'] : (isset($gdInfo['JPG Support']) ? $gdInfo['JPG Support'] : false); - $listOk &= $gdInfo['JPEG Support']; - $listHasErrors |= (! $gdInfo['GIF Read Support'] || ! $gdInfo['JPEG Support'] || ! $gdInfo['PNG Support']); - $testOutput .= getStatus($gdInfo['GIF Read Support'], 'GIF read support', 'You won\'t be able to upload GIF images for your website', true, false); - $testOutput .= getStatus($gdInfo['JPEG Support'], 'JPEG support', 'You won\'t be able to upload JPEG images for your website. Berta won\'t be able to make thumbnails for your images... bad! Ask your server administrator for JPEG support.', true); - $testOutput .= getStatus($gdInfo['PNG Support'], 'PNG support', 'You won\'t be able to upload PNG images for your website', true, false); - } - - // upload sizes ... - $isOk = floatval(ini_get('upload_max_filesize')) >= 256 && floatval(ini_get('post_max_size')) >= 256; - /* $listOk &= $isOk; */ $listHasErrors |= ! $isOk; - $testOutput .= getStatus($isOk, 'Large file uploads (for videos) allowed', - 'Your server runs PHP in CGI mode, which doesn\'t allow tweaking PHP options in .htaccess files. Please tell this to your server administrator and ask for bigger file uploads (over 200Mb for larger videos).', false, false); - - $testOutput .= '
Have you installed your website properly?
A green YES means that you don\'t even need to read what it is about - it\'s just all fine. A yellow NO means that ' . - 'Berta will still work, but the feature will not be available to you. The red NO is the bad one - if there is one, it will have a suggestion ' . - 'what can be done to correct the situation.
'; - - // if the test was ok without any warnings then redirect to the next step - if ($listOk && ! $listHasErrors) { - header('Location: .?_berta_install_step=2' . (! empty($options['MULTISITE']) ? '&site=' . $options['MULTISITE'] : '')); - exit; - } -} - -$version = $options['version']; - -?> - - - -Berta is already installed.
Please delete folder named INSTALL in your Berta's root folder!
' . htmlspecialchars(' ') . '.';
-
- if (! $listHasErrors) {
-
- // normally this is not visible because of a redirect earlier...
-
- echo 'Berta has completed a small test to see if it has everything it needs. It turns out that everything is just perfect.
'; - echo ''; - echo 'Test results:
'; - echo $testOutput; - echo $bottomNote; - - } else { - - // some warnings... - - echo 'Berta has completed a small test to see if it has everything it needs.
'; - echo 'It appears that there are some issues with the server or the installation. You will be able to use Berta, although with limited functionality. Please take a look at the results below.
'; - echo '
If you like to, you can ignore the errors and:
Berta has completed a small test to see if it has everything it needs.
'; - echo 'It turns out that there are some problems with the server or with the installation. Please take a look at the results below and follow the suggestions for each error, and then come back again!
'; - echo 'This server does not meet Berta's requirements.
- Berta needs PHP >= 8.4 support on server.
Berta is already installed.
Please delete folder named INSTALL in your Berta's root folder!
1.
- - - settings->getDefinition('siteTexts', 'siteHeading'), - $berta->settings->get('siteTexts', 'siteHeading', false), - ['xCaption' => str_replace(' ', '+', $berta->settings->getDefinitionParam('siteTexts', 'siteHeading', 'title'))], - 'p', - $basePath . '/siteTexts/siteHeading' - ); - ?> - -2.
- - - settings->getDefinition('texts', 'ownerName'), - $berta->settings->get('texts', 'ownerName', false), - ['xCaption' => str_replace(' ', '+', $berta->settings->getDefinitionParam('texts', 'ownerName', 'title'))], - 'p', - $basePath . '/texts/ownerName' - ); - ?> - -3.
- - - - settings->getDefinition('texts', 'metaDescription'), - $berta->settings->get('texts', 'metaDescription', false), - ['xCaption' => str_replace(' ', '+', $berta->settings->getDefinitionParam('texts', 'metaDescription', 'title'))], - 'p', - $basePath . '/texts/metaDescription' - ); - ?> - - -{% if isEditMode %}