The User Data Folder preference designates which folder, if any, contains Second Site user data files.
The User Data Folder is optional; it is only used for modifications and extensions to Second Site. When used, its contents are used to add or replace entries in the Second Site program folder. The User Data Folder is not modified when you install updates to the Second Site program, so user customizations made via the User Data Folder are undisturbed by program updates.
You can designate any folder on your hard disk as your User Data Folder. I recommend that you make a new folder and use it exclusively for files related to Second Site. Do not use a folder under the Second Site program folder, or anywhere else in the Program Files hierarchy.
The following diagram shows a mock version of a highly-customized User Data Folder. Keep in mind, however, that all the files and folders in the User Data Folder are optional, and a typical User Data Folder will have less content. You supply only the files and folders you need based on how you are extending or modifying Second Site.
- A Site.sdf
- A Site-i
- A Site-o
- My Format.xml
- My Format.xsl
- No Header.ssi
- My Theme
- My Theme
You can use multiple folders as User Data Folders, but only one folder can be active at one time.
You set the User Data Folder via the File > Preferences > Set User Data Folder... command. The command is only available when no SDF file is open: Second Site cannot change the user Data Folder preference when an SDF file is open.
The Set User Data Folder... command opens a window that shows the current User Data Folder path in a text box. You can enter the path by hand, or click the ellipsis ([…]) button to browse for the folder.
You can explore the User Data Folder using the Utilities > User Data Folder > Explore command.
If you use the User Data Folder capability to create a Theme, Format, or Defaults file with the same name as a file supplied with Second Site, your customized file will override the file supplied with Second Site. So, for example, if you create a custom Theme that has the same name as a Theme supplied with the Second Site program, the custom Theme replaces the original Theme. I do not recommend this practice; give your custom files unique names so that you can still access the versions supplied with Second Site.
The modifications and extensions available via the User Data Folder are described below.
If the User Data Folder contains a Scripts subfolder, and within that, a Formats subfolder, Second Site will treat that as an extension of the Formats folder in the Second Site program folder.
Custom Formats defined in the User Data Folder's Scripts\Formats subfolder are listed first in the Style.Formats pull-down menu.
Page Scripts are stored in subfolders beneath the Scripts folder. The Scripts folder and subfolders can be extended via the User Data Folder mechanism, so advanced users can create custom Page Scripts if necessary. See Custom Page Scripts.
The Layouts folder and subfolders can be extended via the User Data Folder mechanism, so users can create custom Layouts. Layouts are complicated, and most users should use one of the 40+ Layouts provided with Second Site. See Custom Layouts.
If the User Data Folder contains a 2ndsite.ini file, the settings in that file override the settings in the 2ndsite.ini file stored in the program folder. Second Site essentially combines the two files, giving preference to the settings from the User Data Folder version.
The 2ndsite.ini file in the User Data Folder should only contain the entries that have been customized by the user. Do not copy all the settings from the 2ndsite.ini file stored in the program folder, just the ones you have changed.
For example, here is a complete 2ndsite.ini file that overrides a single INI parameter:
See the 2ndsite.ini File page for more details.
Custom Autorun Folder
If the User Data Folder contains an Autorun subfolder, Second Site will treat that as a replacement of the Autorun folder in the Second Site program folder.
Custom Defaults Files
If the User Data Folder contains a Defaults subfolder, Second Site will treat that as an extension of the Default Values folder in the Second Site program folder. This is the recommended place for custom Defaults files.
Custom Defaults files in the User Data Folder's Defaults subfolder are listed first in the Set Default Values dialog that appears when you create a new SDF file.
In Second Site it is rarely necessary to create a custom Theme, but if you wish to do so, you can create one via the User Data Folder.
If the User Data Folder contains a Themes subfolder, Second Site will treat that as an extension of the "Themes" folder in the Second Site program folder.
Custom Themes defined in the User Data Folder's Themes subfolder are listed first in the Styles.Themes pull-down menu.
Custom Theme developers may create a thumbnail image for their Theme. See the Themes page for details.
User Data Folder Example
For the example below, assume the user created a folder named c:\UDF\ and then used the Second Site command File > Preferences > Set User Data Folder... to set the UDF folder to c:\UDF\
Further assume that the user has created a custom Theme called "My Theme", including the Theme script file Theme.sss, and placed it in the proper location. The resulting folders look like this:
- c:\Program Files\Second Site
- Plain Blue
- My Theme
- My Theme
The UDF includes a Themes subfolder, which in turn includes a folder named My Theme. Second Site searches the UDF folder whenever it opens an SDF file or creates a new one and will take note of any custom Themes at that time. In this example, "My Theme" will be added to the list of Themes in the Styles.Theme pull-down menu in the Second Site user interface. If the user subsequently chooses that Theme from the list, Second Site will store the Theme name in the SDF file and execute the Theme script stored in c:\UDF\Themes\My Theme\Theme.sss to update the Stylesheets.Theme section of the user interface.
When Second Site makes the site, it copies all the files in the folder c:\UDF\Themes\My Theme\ to the Output folder.
Note Unlike previous versions of Second Site, no files are copied to the Input (-i) folder from the Theme folder.
This page last changed on 02 Aug 2011.