In Contensis R8.2 we overhauled the way we name content, and we’ve done so inline with the universal resource identifier syntax, the RFC document outlines what should and shouldn’t be present in a URL. We’ve also introduced a setting for casing, allowing you to enforce a consistent convention across your website and meet your content or style guidelines.
This article aims to explain how to configure the content renaming and what the expected behaviour should be. The way Contensis handles filenames is determined by a series of hard coded and project settings:
Reserved (hard coded) characters
The following characters are reserved in the URL syntax and will be removed if AutomaticContentRenaming is enabled.
|\, ;, /, ?, :, @, &, =, +, $, (comma), <, >,|, *, double quote (")
These are characters that whilst not reserved from the URL syntax are not recommended to be used, some operating systems / browsers may have issues if the URL contains these characters. This setting is a comma separated list allowing you to remove characters that you feel are necessary for your project.
The content casing setting determines what type of casing should be applied to your content names during creation.
- Unchanged - e.g. Nothing changes with casing
- Title casing - e.g. Title-Casing-Should-Look-Like-This
- Pascal casing - e.g. PascalCasingShouldLookLikeThis
- Sentence casing - e.g. Sentence casing should just be like this
- Lower casing - e.g. should look like this
This setting determines the type of content renaming that should be applied.
- Disabled - Content renaming is completely disabled, including the Characters to remove, and invalid XML characters, and casing rules.
- Enabled - Reserved and optional characters are removed, and casing rules are applied.
This setting was previously called ContensisNameSeparator. This setting determines what the content rename should do when it finds a space in the filename. Setting it to a value other than a hyphen, blank, or underscore, will produce a server error informing you an invalid character has been used.
Note: If the space separator is set to a space, we will automatically replace the space with a hyphen. This is due to producing poor URL structures such as http://yourdomain.com/my%20folder/my%20other%20folder/. If you would prefer to use spaces then we recommend setting the ContentName_AutomaticContentRenaming to disabled
This setting was previously called ContensisNameSeparator_ApplyToBulkUpload. This setting determines if the SpaceSeparator setting should be applied when extracting the contents of a zip file.
Defaults for new projects
When you create a new project in Contensis we set some defaults for you:
User configurable settings Project Setup > Settings
||1 = Enabled
||0 = Unchanged
||- Set to a hyphen
Defaults for existing projects
When you upgrade to R8.2 the settings may differ to the defaults above based on existing settings:
||1 = Enabled
||0 = Unchanged 1
1 If the contensis name separator was blank when you upgrade then the casing will be set to PascalCase
2 If the character is set to a space, then we will automatically replace it with a hyphen