-
Notifications
You must be signed in to change notification settings - Fork 91
[(base_path)] placeholder not parsed in settings.php #2272
Description
Environment:
CMS Version: Evolution CMS 3.x
PHP Version: 8.x
Database: MySQL / SQLite
Summary:
The system placeholder [(base_path)] is not being parsed/resolved when defined manually in core/custom/config/cms/settings.php for the configuration parameters filemanager_path and rb_base_dir.
Steps to Reproduce:
Open your configuration file: core/custom/config/cms/settings.php
Manually define the file manager and resource browser paths using the base path placeholder:
return [
'filemanager_path' => "[(base_path)]",
'rb_base_dir' => "[(base_path)]assets/",
];
Save the file and clear the CMS cache.
Navigate to Elements > Manage Files or try to upload an image via a Template Variable (Image) using the Resource Browser.
Expected Result:
The CMS should resolve [(base_path)] to the absolute server path (e.g., /var/www/public_html/), allowing the File Manager to list files correctly.
Actual Result:
The placeholder remains as a literal string [(base_path)]. As a result, the File Manager fails to load, often showing an error that the directory does not exist or displaying an empty file list because the path is invalid.
Additional Context:
Currently, these settings only seem to work if hardcoded as absolute strings or if defined via the Manager GUI (which saves them to the database). When the CMS boots and loads settings.php, the parser for global placeholders is not yet applied to these specific filesystem configuration keys.
