How to configure the basic settings and general behaviour of Litium.
Account settings
General settings for users in Litium.
Section: litium / foundation / accountsettings
System user
All settings for the system user.
Section: litium / foundation / accountsettings / systemUser
- enabled: If the user can log in to Litium with Windows credentials from a remote site (login is always enabled when browsing the site from localhost), only members of the local group Administrators can log in. To change group to not use local administrators, see the systemUserGroup attribute.
- useSecureConnectionRedirection: If the system should try to redirect the administrator to use https instead of http.
- systemUserGroup: Change group to another group than the local Administrators group. Set the name or the SID of the group name according to the pattern "[computername]\[Groupname]" as the value. To allow the local group LitiumBackoffice to access the administration interface, the value computer\LitiumBackoffice should be set, where computer is your local computer name. If any built-in group should be used, the computer should be replaced with builtin.
The group can also be changed per server by adding the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Litium\LitiumStudio\SystemUserGroup as DWORD with the value of the SID or the group.
To use the system account, log in using an account with admin privileges on the local machine or domain.
Password policy
Define the password policy, used for all users in Litium.
Section: litium / foundation / accountsettings / passwordPolicy
- lockoutCount: The number of incorrect password attempts allowed before the account is locked. -1 is unlimited.
- lockoutSeconds: The number of seconds the account should be locked when LockoutCount has been exceeded.
- expirePeriodInDays: The number of days the user password will be valid. -1 is unlimited.
- complexityRule: If set to true the password needs to contain at least one character of each of the following types, non-letter or digits, digits, lowercase letter, uppercase letter.
- lengthRule: If set to true the password must contain at least 6 characters.
Back to the top
This section describes how to add custom pages into System Settings.
Section: litium / foundation / controlPanelPages / Group settings
Add a group element with an attribute systemStringKey that contains the key for the resource string to use in the left menu. Inside the group element, add a controlPanelPage element for each page that you want to add
- page: The URL to the page. The path starts from /LitiumStudio/Foundation/.
- icon: The path to the icon that will be used for the page.
- systemStringKey: The key for the value that should be used as the page name. Language dependent.
- permission: Defines the kind of permission that users need to have in order to access the page.
Example
<controlPanelPages>
<projectSettings systemStringKey="ProjectSettings.Title.Key">
<controlPanelPage
page="/Site/LitiumStudio/ControlPanelPages/Tasks.aspx"
icon="/Site/LitiumStudio/ControlPanelPages/Images/gear_time.png"
systemStringKey="Tasks"
permission="All" />
</projectSettings>
</controlPanelPages>
Back to the top
This section describes how to add scheduled tasks or start up tasks.
Section: litium / foundation / taskSettings
Scheduled task
Section: litium / foundation / taskSettings / scheduledTasks
Scheduled tasks are background tasks that are run periodically. Add a scheduledTask element for each task you want to execute in a specific time range. You need to specify the start time and interval for each task.
- type: Full name and assembly of the class to run.
- startTime: The time when the task should be started. If the task should run more than once per day, the first possible occurence will be found based on interval.
- interval: Periodicity. Can be d (days), h (hours), m (minutes), e.g. 2d (every second day), 30m (every 30 minutes).
- parameters: Parameters sent to the task, optional.
- allowOn: "computer:sitename,computer:sitename" - optional. Wildcards (*) can be used for both "computer:sitename" to match all.
Some common examples:
- LogTruncateScheduler: Truncates the system log. The system log contains information about errors and other events, and can be viewed in back office in Settings > System settings > Event log.
- CampaignDeactivator: Deactivates campaigns that have passed the campaign end date.
- StatisticScheduler: Collects data for reports and webcontrols, for example about most sold articles.
- CleanUpUrlHistory: Removes URL history older than a specified number of days.
- PaymentStatusSynchronizer: Synchronizes orders with the payment status Pending with the payment provider.
<taskSettings>
<scheduledTasks>
<scheduledTask type="Litium.Foundation.Log.ScheduledTasks.LogTruncateScheduler, Litium.Foundation" startTime="00:30" interval="2h" parameters="Trace=1, Debug=2, Info=10, Warn=25, Error=100, Fatal=-1, MaxCount=-1" />
<scheduledTask type="Litium.Foundation.Search.IndexOptimization, Litium.Foundation" startTime="02:00" interval="1d" />
<scheduledTask type="Litium.Foundation.Modules.CMS.Pages.PageMaintenance, Litium.Studio" startTime="00:00" interval="1m" />
<scheduledTask type="Litium.Foundation.Modules.CMS.Routing.ScheduledTasks.CleanUpUrlHistory, Litium.Studio" startTime="00:00" interval="1d" parameters="Count=50000, Days=90" />
<scheduledTask type="Litium.Foundation.Modules.CMS.SiteMaps.SiteMapScheduler, Litium.Studio" startTime="00:25" interval="24h" />
<scheduledTask type="Litium.Foundation.Modules.ECommerce.Campaigns.CampaignDeactivator, Litium.Studio" startTime="00:05" interval="1d" />
<scheduledTask type="Litium.Foundation.Modules.ECommerce.Payments.PaymentStatusSynchronizer, Litium.Studio" startTime="00:00" interval="2h" />
<scheduledTask type="Litium.Foundation.Modules.ECommerce.Statistics.StatisticScheduler, Litium.Studio" startTime="00:20" interval="1d" parameters="MaxOrderAgeInMonths=6, OrderStates=1;2;3, RelationsLimit=25" />
<scheduledTask type="Litium.Foundation.Modules.ECommerce.Orders.OrderCleanupScheduler, Litium.Studio" startTime="00:40" interval="1d" />
<scheduledTask type="Litium.Web.Customers.TargetGroups.CleanupScheduler, Litium.Web.Application" startTime="00:13" interval="1d" />
<scheduledTask type="Litium.Web.Products.PriceAgents.PriceAgentScheduler, Litium.Web.Application" startTime="00:35" interval="1d" />
</scheduledTasks>
<startupTasks>
</startupTasks>
</taskSettings>
Startup task
Section: litium / foundation / taskSettings / startupTasks
Add a startupTask element for each task you want to execute during solution startup.
- type: Full name and assembly of the class to run.
- parameters: Parameters sent to the task, optional.
- allowOn: "computer:sitename,computer:sitename" - optional. Wildcards (*) can be used for both "computer:sitename" to match all.
Back to the top
This section describes the files directory, SMTP server and startup information.
Section: litium / foundation / general
Files directory
Section: litium / foundation / general / filesDirectory
- Value: Upload folder where files are stored.
Common files directory
Section: litium / foundation / general / commonFilesDirectory
When using multiserver environments the commonFilesDirectory should be set in web.config.
This directory is used to store all the information that is common between the servers.
If this tag is not present, a folder named Storage within the folder set in filesDirectory will be used.
- Value: Upload folder where files that are common to all servers are stored.
SMTP server
Section: litium / foundation / general / smtpServer
- Value: SMTP server to use inside Litium Studio.
EventLog settings
Section: litium / foundation / general / eventLog
If you would like to configure the settings for how the event log is treated, add the eventLog element in the Web.config file.
- maxAgeInMinutes = the maximum number of minutes for values retained in the event log. Note: If the value is set too high the startup might be slower, due to reading of old events.
- deleteInterval = the interval for deleting old values from the event log. Note: A low value shortens the event log but also increases the number of queries sent to the database.
- pollingInterval = the interval for checking the event log for new events raised at other servers. Note: A low value increases the number of queries sent to the database. In a single server setup there is no need to change this value.
<eventLog maxAgeInMinutes="60" deleteIntervalInMinutes="60" pollingIntervalInSeconds="5"/>
Back to the top
Search settings for the current solution of Litium.
Section: litium / foundation / search
- enableChangeTracking: If set to true the search indexes will be synchronised with the underlying repository by listening to events raised on data changes. This will affect the performance slightly. If set to false, indexes will not be updated until you manually update them. This can be used when performing larger import jobs, and it is often combined with a scheduled task that updates the indexes during the night.
- backOfficeFuzzySearchSimilarity: Fuzzy search similarity for backoffice.
- publicSiteFuzzySearchSimilarity: Fuzzy search similarity for public site.
Back to the top
Routing
Settings for handling URL routing in Websites. Add a disabledRoutingPath element for each route you want to disable.
Section: litium / studio / cms / routing.
- path: the path to be disabled, relative to the root.
Back to the top
Settings for the Sales area.
Section: litium / studio / ecommerce
- orderExportXslt: If an XSLT file is specified here, it will be used to transform the exported orders in the Order Export feature. The user will only get the transformed XML file. The XSLT file should reside in the /Bin directory.
- gateWayIP: If the web server is behind a firewall with port forwarding, this needs to be set to the visible public IP (example: "http://203.94.70.123"). Used for communication with providers.
Back to the top
Settings for the storage handler.
Section: litium / studio / storage
- useCdn: Determines if CDN support is enabled.
- useSecureCdn: Determines if CDN should be enabled on secured pages (SSL).
- cdnHost: Hostname for the CDN network.
- cdnSecureHost: Hostname for the CDN network when browsing over SSL.
Back to the top
Litium loads all plugin assemblies in the web\bin folder by default using IoC (Inversion of Control). The assemblies listed in this section will not be loaded by the plugin loader.
Section: litium / foundation / plugins / assemblies
- add: Add the assemblty to be loaded first for dependency injection.
- remove: Prevents the specified assembly from being loaded.
The following example instructs the IoC infrastructure not to load the plugins from Litium.Studio.Sample.dll.
<remove assembly="Litium.Studio.Sample"/>
Section: litium / foundation / plugins / types
- remove: Prevents the specified type from being loaded.
The following example instructs the IoC infrastructure not to load the plugin Company.MyClass from Litium.Studio.Sample.dll.
<remove type="Company.MyClass, Litium.Studio.Sample"/>
Back to the top
This section describes how to change the SQL time out settings for specific SQL stored procedures.
Add a commandTimeOut element per stored procedure.
Section: litium / commandTimeouts
- Command: The name of the stored procedure.
- Timeout: Time in seconds.
Back to the top
Error messages
To get more detailed error messages during development you can make the following settings:
Section: system.web
- compilation debug: Set to true.
- customErrors mode: Set to Off.
With the customErrors mode you can configure what should happen when an unhandled error occurs during the execution of a request. This makes it possible to display an HTML error page instead of an error stack trace. The options are Off, On, and RemoteOnly.
<customErrors mode="Off" defaultRedirect="~/Site/CMS/Error.aspx">
<error statusCode="404" redirect="~/Site/CMS/PageNotFound.aspx" />
</customErrors>
Note: It is important to reset these values when the website goes live, otherwise the performance will decrease.
Back to the top
Application restart
During development you usually save pages over and over again. If the value for numRecompilesBeforeAppRestart is set too low, it will force the application to restart and you will be logged out. You can change this setting to a higher value during the development phase to save you some inconvenience.
The numRecompilesBeforeAppRestart sets how many pages you can save before the application restarts. You can choose any number and it does not affect the App_Code folder.
Section: system.web
- compilation numRecompilesBeforeAppRestart​: Number of pages that can be saved before the application restarts.
<system.web>
<compilation numRecompilesBeforeAppRestart="500">
</compilation>
</system.web>
Back to the top
This option is availble from Litium version 7.2. By default, the prefix for an order number is LS. For a delivery number the prefix is LSD. You can change them by adding a configuration to appSettings in Web.config,as follows:
<appSettings>
<add key="Litium:Sales:OrderNumberPrefix" value="LS" />
<add key="Litium:Sales:DeliveryNumberPrefix" value="LSD" />
</appSettings>
Back to the top