Forum Configuration

Forum Configuration

Configuration File

Flatboard 5 stores its main configuration in /stockage/json/config.json.

Configuration Structure

{
  "site_name": "My Forum",
  "site_url": "https://example.com",
  "base_url": "",
  "default_language": "fr",
  "timezone": "Europe/Paris",
  "storage_type": "json",
  "debug": false,
  "maintenance_mode": false,
  "registration_enabled": true,
  "email_verification": false,
  "pagination_type": "classic",
  "smtp": {
    "enabled": false,
    "host": "",
    "port": 587,
    "username": "",
    "password": "",
    "from_email": "",
    "from_name": ""
  },
  "assets": {
    "minify_css": true,
    "minify_js": false,
    "cache_enabled": true
  }
}

General Settings

Site Information

Access: Admin Panel > Settings > General

  1. Site Name - Your forum's display name

    • Appears in page titles, headers, and emails
    • Maximum 100 characters
  2. Site URL - Full URL including protocol

    • Format: https://example.com or http://example.com
    • Used for email links and redirects
  3. Site Description - Brief description for SEO

    • Appears in meta tags
    • Recommended: 150-160 characters
  4. Base URL - Subdirectory path if installed in subfolder

    • Leave empty if installed in root
    • Example: /forum if installed at https://example.com/forum

Language and Timezone

Configure localization settings:

  • Default Language - Choose from available languages

    • Available: English (en), French (fr), and more
    • Users can override in their profile
  • Timezone - Set your server's timezone for correct timestamps

Storage Configuration

Storage Type:

  • JSON - File-based storage (default, all editions)
  • SQLite - Database storage (Pro Edition only)

User Settings

Registration

  • Enable Registration - Allow new users to register

    • When disabled, only admins can create accounts
  • Email Verification - Require email verification

    • Users must verify email before account activation
    • Requires SMTP to be configured
  • Default User Group - Group assigned to new users

    • Typically: "Member" or "Guest"

Profile Settings

  • Allow Avatar Upload - Enable user avatar uploads
  • Avatar Max Size - Maximum file size (e.g., 2MB)
  • Avatar Dimensions - Maximum width/height (e.g., 200x200)
  • Allow Signature - Enable user signatures in posts
  • Signature Max Length - Maximum characters (e.g., 500)

Email Configuration

SMTP Settings

Access: Admin Panel > Settings > Email

Configure SMTP for reliable email delivery:

  1. Enable SMTP - Turn on SMTP sending
  2. SMTP Host - Your mail server (e.g., smtp.gmail.com)
  3. SMTP Port - Usually 587 (TLS) or 465 (SSL)
  4. Username - SMTP authentication username
  5. Password - SMTP authentication password
  6. From Email - Sender email address
  7. From Name - Sender display name

Common SMTP Providers

Gmail:

Host: smtp.gmail.com
Port: 587
Encryption: tls
Username: [email protected]
Password: (App Password, not regular password)

Outlook/Office 365:

Host: smtp.office365.com
Port: 587
Encryption: tls

SendGrid:

Host: smtp.sendgrid.net
Port: 587
Encryption: tls
Username: apikey
Password: (Your SendGrid API key)

Test Email

Use the "Send Test Email" button to verify your SMTP configuration.

Security Settings

CSRF Protection

  • Enabled by default - Protects against Cross-Site Request Forgery
  • No configuration needed - automatically handled

Rate Limiting

Configure request rate limits:

  • Login Attempts - Max attempts per IP (default: 5)
  • Registration Attempts - Max registrations per IP (default: 3)
  • Password Reset - Max requests per hour (default: 3)

Password Requirements

  • Minimum Length - Minimum password characters (default: 8)
  • Require Uppercase - Require uppercase letters
  • Require Numbers - Require numeric characters
  • Require Special Characters - Require special chars (!@#$% etc.)

Performance Settings

Caching

  • Enable Cache - Enable Markdown and template caching
  • Cache Duration - Cache lifetime in seconds (default: 3600)

Asset Optimization

  • Minify CSS - Automatically minify CSS files
  • Minify JavaScript - Automatically minify JS files
  • Combine Assets - Combine multiple files into one

Maintenance Mode

Access: Admin Panel > Settings > Maintenance

Enable maintenance mode to perform updates or maintenance:

  • Maintenance Mode - Enable/disable
  • Maintenance Message - Message shown to visitors
  • Allow Admin Access - Admins can still access during maintenance

Advanced Settings

Debug Mode

  • Debug Mode - Enable detailed error messages
    • Never enable in production - Security risk
    • Use only for development/troubleshooting
    • When enabled, HTML assets (CSS/JS) are not minified - Assets are served in their original, readable format for easier debugging
    • When enabled, the Maintenance Tools section becomes visible in the Admin Dashboard — All rebuild, cleanup, and file-permission actions (Admin → Dashboard → Maintenance) are hidden in production and only appear when debug is true. A warning notice is displayed inside the section to remind administrators that these tools are exposed because debug mode is active.

Logging

  • Enable Logging - Log errors and events
  • Log Level - error, warning, info, debug
  • Log File - Location: /stockage/logs/

SEO Settings

  • Meta Title - Default page title
  • Meta Description - Default meta description
  • Meta Keywords - Default keywords (comma-separated)
  • Enable Sitemap - Generate sitemap.xml
  • Enable Robots.txt - Generate robots.txt

Configuration via Admin Panel

Most settings can be configured through the admin panel:

  1. Navigate to Admin Panel - /admin
  2. Go to Settings - Click "Settings" in the menu
  3. Select Category - General, Users, Email, Security, etc.
  4. Modify Settings - Change values as needed
  5. Save Changes - Click "Save" button

Configuration via CLI

Some settings can be configured via command line:

# Set a configuration value
php app/Cli/console.php config:set site_name "My Forum"

# Get a configuration value
php app/Cli/console.php config:get site_name

# List all configuration
php app/Cli/console.php config:list

# Reload config from disk (discards in-memory cache — useful after manual edits)
php app/Cli/console.php config:reload

Backup Configuration

Always backup your configuration before making changes:

# Backup config.json
cp stockage/json/config.json stockage/json/config.json.backup

# Restore from backup
cp stockage/json/config.json.backup stockage/json/config.json

Troubleshooting Configuration

Settings Not Saving

Possible causes:

  • Insufficient file permissions
  • Configuration file locked
  • Disk space full

Solution:

chmod 600 stockage/json/config.json
chown www-data:www-data stockage/json/config.json

Email Not Sending

Check:

  1. SMTP settings are correct
  2. Firewall allows outbound connections on SMTP port
  3. Credentials are valid
  4. Test email function works

Timezone Issues

Solution: Use proper timezone identifier:

  • Correct: Europe/Paris
  • Incorrect: Paris, GMT+1, UTC+1

Resources

Last updated: February 26, 2026