SurgeWeb Configuration and Customisation

  1. Home
  2. Knowledge Base
  3. SurgeWeb
  4. SurgeWeb Configuration and Customisation

Surgeweb is configured using a system of customisation that allows settings, styling and behaviour changes to be applied “over top of” the existing core interface. Virtually all surgeweb customisation can be configured globally, per domain, per user group, and most behaviour can be configured per account either manually by the admin or by the user.

Customisation gets applied using settings in config_*.dat files, using extension css and extension javascript files. In addition there are a small number of surgeweb related surgemail.ini settings.

Locations on Disk

There are three primary surgeweb folder trees:

  • surgemail/surgeweb/tpl : This defines the whole of the surgeweb clientside interface in terms of javascript, html, css and default settings. This folder should not be directly modified and will get completely overwritten on upgrades.
  • surgemail/surgeweb/custom : The surgeweb customisation folder. This is where all your customisation would generally be made. This includes global, per domain and per user group customisation. This folder remains intact on upgrades.
  • surgemail/surgeweb/work : This is the surgeweb work folder where all per user files are stored. You generally should not modify this directly unless you are doing some very specialised administration.

Config files

The majority of surgeweb configuration options are configured using the config_*.dat files. These are self documenting plain text files that control the behaviour of just about everything is surgeweb. Subsequent levels of specialisation will override the settings at a more general level. A subset of the settings available in these files can be edited using the surgeweb customisation page of the surgemail admin interface.

  • surgemail/surgeweb/tpl/config_system.dat : The system default behaviour. Never edit this. This is the primary reference for available settings and valid values for these settings.
  • surgemail/surgeweb/custom/config_global.dat : Surgeweb customisation that will be applied globally. This is where changes get saved if you edit within the global scope on the surgeweb customisation page of the admin interface. You may have to add the settings in question to this file.
  • surgemail/surgeweb/custom/domain.com/config_domain.dat : Per domain customisation. This file gets created on demand if you save from the admin interface using the domain scope. If manually editing the settings you may need to create this file.
  • surgemail/surgeweb/custom/access_group_{group_name}/config_group.dat : As for config_domain.dat but applied on a surgemail user group basis.

Within the config files a leading # character indicates that the line is a comment line.

User settings

Surgeweb configuration info related to individual users is stored in the folder: surgemail/surgeweb/work/{hash}/{username}

The file _user.dat has most configuration info of note. This includes all options selected in the surgeweb interface. In addition to this most of the settings that apply to config_*.dat can be applied per user by adding these explicitly to the _user.dat file.

Within the _user.dat file a leading # character indicates that the line is a comment line. For a particular user, the surgeweb work location can be found using “tellmail swpath user@domain” on the command line.

WARNING: Availability of Customisation Features

Up until the introduction of the interface changes of g_modern_surgeweb, there has been a very strong focus on backward compatibility of all features and having all customisation features available under the surgeweb interface.

With the introduction of g_modern_surgeweb some of the customisation features of old no longer apply, and some will need to get applied in different ways.

Was this article helpful?

Related Articles