-#Shaarli configuration
-# Shaarli configuration
-
## Foreword
**Do not edit configuration options in index.php! Your changes would be lost.**
Once your Shaarli instance is installed, the file `data/config.json.php` is generated:
* it contains all settings in JSON format, and can be edited to customize values
-* it defines which [plugins](Plugin-System) are enabled[(.html)]((.html).html)
+* it defines which [plugins](Plugin-System) are enabled[](.html)
* its values override those defined in `index.php`
* it is wrap in a PHP comment to prevent anyone accessing it, regardless of server configuration
- to give it access to Shaarli, either:
- unzip Shaarli in the default web server location (usually `/var/www/`) and set the web server user as the owner
- put users in the same group as the web server, and set the appropriate access rights
-- if you have a domain / subdomain to serve Shaarli, [configure the server](Server-configuration) accordingly[(.html)]((.html).html)
+- if you have a domain / subdomain to serve Shaarli, [configure the server](Server-configuration) accordingly[](.html)
## Configuration
In `data/config.json.php`.
-See also [Plugin System](Plugin-System.html).[](.html)
+See also [Plugin System](Plugin-System.html).
### Credentials
**title**: Shaarli's instance title.
**header_link**: Link to the homepage.
**links_per_page**: Number of shaares displayed per page.
-**timezone**: See [the list of supported timezones](http://php.net/manual/en/timezones.php). [](.html)
+**timezone**: See [the list of supported timezones](http://php.net/manual/en/timezones.php).
**enabled_plugins**: List of enabled plugins.
### Security
**ban_after**: Failed login attempts before being IP banned.
**ban_duration**: IP ban duration in seconds.
**open_shaarli**: Anyone can add a new link while logged out if enabled.
-**trusted_proxies**: List of trusted IP which won't be banned after failed login attemps. Useful if Shaarli is behind a reverse proxy.
+**trusted_proxies**: List of trusted IP which won't be banned after failed login attemps. Useful if Shaarli is behind a reverse proxy.
+**allowed_protocols**: List of allowed protocols in shaare URLs or markdown-rendered descriptions. Useful if you want to store `javascript:` links (bookmarklets) in Shaarli (default: `["ftp", "ftps", "magnet"]`).
### Resources
"ban_after": 4,
"session_protection_disabled": false,
"ban_duration": 1800,
- "trusted_proxies": [[](.html)
+ "trusted_proxies": [
"1.2.3.4",
"5.6.7.8"
+ ],
+ "allowed_protocols": [
+ "ftp",
+ "ftps",
+ "magnet"
]
},
"resources": {
"enable_localcache": true,
"check_updates_branch": "stable",
"check_updates_interval": 86400,
- "enabled_plugins": [[](.html)
+ "enabled_plugins": [
"markdown",
"wallabag",
"archiveorg"
"general": {
"header_link": "?",
"links_per_page": 20,
- "enabled_plugins": [[](.html)
+ "enabled_plugins": [
"markdown",
"wallabag"
],
## Additional configuration
The playvideos plugin may require that you adapt your server's
-[Content Security Policy](https://github.com/shaarli/Shaarli/blob/master/plugins/playvideos/README.md#troubleshooting) [](.html)
-configuration to work properly.[(.html)]((.html).html)
+[Content Security Policy](https://github.com/shaarli/Shaarli/blob/master/plugins/playvideos/README.md#troubleshooting)
+configuration to work properly.[](.html)