Understanding siteaccesses and settings
Almost everything Exponential does is decided by a setting, and every request comes in through a siteaccess. When a change "has no effect", one of these two ideas is usually the reason. This page explains both for learners and shows how to ask the installation itself.
Contents
Siteaccesses
A siteaccess is one way of reaching the site (by URL, host or port) with its own settings and design
(Glossary). Every installation has three, always called site, admin and editor
(Installing Exponential 6.0):
| Siteaccess | For | With exp:install on its defaults |
|---|---|---|
site | Visitors | the path /site |
admin | Administrators | the path /admin |
editor | Editors: the administration for content only, without setup, design and developer tools | the path /editor |
A site package can add more. The default sevenx_multisite adds bold and bold_ger for its second website
(Site packages for learners). A multilingual site usually has one public siteaccess
per language (Content languages).
Each siteaccess has its own folder of settings, settings/siteaccess/<name>/.
Settings files
- The defaults are in
settings/*.ini:site.ini,content.ini,design.ini,override.iniand many more. - You never edit these files: they are replaced at every upgrade. You add files with the same name and the
suffix
.ini.append.phpin a place that is read after them. - A setting is named by file, block and variable:
site.ini [SiteSettings] SiteName, or for the settings commandsite.ini/SiteSettings/SiteName.
Source: How INI settings work.
Which file wins
After the default file, the kernel reads the other places in this order, and a later file wins:
- the per-siteaccess folders inside extensions,
settings/siteaccess/<siteaccess>/,extension/<ext>/settings/of each active extension,settings/override/.
Source: Settings scopes and the order they win in.
Note the surprise in step 3: a value an extension ships beats the same value in settings/siteaccess/<sa>/.
Ask the installation
You do not have to work the order out by hand. exp:ini where shows every file that sets a value, in load order,
and the value in effect (Templates and design):
php bin/php/console exp:ini where site/DesignSettings/SiteDesign siteThe output lists the files, for example settings/site.ini with SiteDesign=admin and then the siteaccess file,
and ends with In effect: and the design used. Replace site at the end with the siteaccess you study. The command
can also read, set and add values; see exp:ini and
The exp:ini command.
After you change a setting, the INI cache may still hold the old value. Clear it as described in Understanding caches.
Common mistakes
| Mistake | What happens | Instead |
|---|---|---|
Editing settings/site.ini | Lost at the next upgrade | Use an .ini.append.php file in settings/override/ or a siteaccess folder |
Changing the site siteaccess and looking at bold | No change where you look | Find the siteaccess of the page you look at |
Setting a value in settings/siteaccess/<sa>/ that an extension also sets | The extension's value wins | settings/override/, or list the extension in that siteaccess's ActiveAccessExtensions[] instead (its own siteaccess folder is read before yours and does not help) |
Writing true where the default uses enabled | The switch does not work | Use the form the default file uses |
| Forgetting the cache | The old value stays | Clear the INI cache |
| Putting a password into a settings file you commit | The password is published | Keep settings/override/ and its secrets out of public repositories |
Exercises
- List the folders in
settings/siteaccess/of your study site. Which siteaccesses exist? - Run
exp:ini where site/DesignSettings/SiteDesignfor two of them. Do they use the same design? - Find
SiteLanguageListfor thesitesiteaccess withexp:ini where site/RegionalSettings/SiteLanguageList site. Which languages does it show, in which order? - Explain to a fellow learner, in three sentences, why a value from an extension can beat a siteaccess value.
The trainers' course Multisite and site packages and the builder chapters Siteaccess settings go further.
Related pages
- Understanding caches
- Learning path: administrator
- Understanding the content model
- Free documentation: this page is free to copy, translate and improve under the GNU FDL 1.3.
Become an Exponential Partner
Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.