Comprehensive guide to the FileRack website launcher system
🌟 System Overview
FileRack is a comprehensive multi-user website launcher system that allows users to organize and access their favorite websites through a clean, tile-based interface. The system supports multiple users, each with their own personalized dashboard of website tiles organized into customizable categories.
Key Features:
Multi-user support with secure authentication
Customizable categories for organizing websites
Drag-and-drop reordering of categories and website tiles
Default categories for new user setup
Custom icon support for website tiles
Responsive design that works on all devices
Advanced diagnostics system for maintenance and troubleshooting
🏗️ System Architecture
FileRack follows a modern web application architecture built on PHP and MySQL with a focus on security, performance, and maintainability.
Technology Stack
Backend: PHP 8.x
Database: MySQL/MariaDB
Frontend: HTML5, CSS3, JavaScript
Server: Apache with mod_rewrite
Directory Structure
filerack.com/
├── index.php # Main entry point
├── dashboard.php # User dashboard
├── login.php # Login page
├── register.php # Registration page
├── api/ # API endpoints for AJAX operations
│ ├── save-service.php
│ ├── save-settings.php
│ ├── update-click.php
│ └── update-order.php
├── assets/ # Static assets
│ ├── css/
│ ├── js/
│ └── images/
├── config/ # Configuration files
│ └── config.php # Main configuration
├── includes/ # PHP includes and utilities
│ └── functions.php # Helper functions
├── Diags/ # Diagnostics system
└── templates/ # Email templates
🗄️ Database Schema
The FileRack system uses a relational database with the following main tables:
users
Stores user account information and authentication data.
Column
Type
Description
id
INT AUTO_INCREMENT
Primary key
username
VARCHAR(255)
Unique username
email
VARCHAR(255)
User's email address
password_hash
VARCHAR(255)
Securely hashed password
created_at
DATETIME
Account creation timestamp
email_verified
TINYINT(1)
Whether email has been verified
categories
Stores user-created categories for organizing website tiles.
Column
Type
Description
id
INT AUTO_INCREMENT
Primary key
user_id
INT
Foreign key to users table
name
VARCHAR(255)
Category name
is_default
TINYINT(1)
Whether this is a default category
order_position
INT
Display order position
services
Stores individual website tiles with their properties.
Column
Type
Description
id
INT AUTO_INCREMENT
Primary key
user_id
INT
Foreign key to users table
category_id
INT
Foreign key to categories table
name
VARCHAR(255)
Website name
url
VARCHAR(2048)
Website URL
description
TEXT
Optional description
icon_url
VARCHAR(2048)
URL to website icon
order_position
INT
Display order within category
default_categories
Stores system-wide default categories available to new users.
Column
Type
Description
id
INT AUTO_INCREMENT
Primary key
name
VARCHAR(255)
Category name
description
TEXT
Category description
sites
JSON
JSON array of default websites
display_order
INT
Display order for categories
user_settings
Stores user-specific settings and preferences.
Column
Type
Description
user_id
INT
Foreign key to users table
background_color
VARCHAR(20)
User's preferred background color
button_color
VARCHAR(20)
User's preferred button color
open_behavior
VARCHAR(20)
Link opening behavior (new tab, same tab)
Note: Additional tables like password_resets are used for specific functionality but are not core to the system's operation.
🔐 Authentication System
FileRack implements a secure, modern authentication system with multiple security features:
Registration Process
Users provide username, email, and password
Email verification sent via SMTP
Account remains limited until email verified
Google reCAPTCHA v2 protects against bots
Password Security
Passwords are secured using PHP's password_hash() function with the following features:
Modern bcrypt hashing algorithm
Automatic salt generation
Configurable cost factor (default: 12)
No plain passwords stored anywhere in the system
Known Issue: Password Hash Corruption
In some hosting environments, database corruption can occasionally affect password hashes, causing login failures. The diagnostics system includes tools to detect and repair this issue.
Session Management
Secure PHP sessions with anti-hijacking protections
CSRF token protection on all forms
Configurable session timeout
IP-based session validation (optional)
📋 Default Categories System
The default categories system provides new users with a pre-populated set of website categories and links to get started with FileRack quickly.
How It Works
System-wide default categories are stored in the default_categories table
When a new user registers, they can choose which default categories to import
Selected categories are copied to the user's personal categories
Users can then customize, add, or remove these categories and websites
Default Category Structure
Each default category is stored as a JSON object containing:
name: Category name (e.g., "General", "Business")
description: Category description
sites: JSON array of website objects:
name: Website name
url: Website URL
description: Optional description
Management Tools
The Diagnostics system includes tools to manage default categories:
default_category_tool.php: Visual editor for categories and sites
default_categories_check.php: Diagnostic tool
default_category_rebuild.php: Recovery tool
Changes to default categories only affect new users. Existing users' dashboards are not affected.
🔧 Diagnostics System
The FileRack Diagnostics System is a comprehensive toolkit for monitoring, troubleshooting, and maintaining the FileRack platform.
Core Diagnostic Tools
System Health Monitor: Checks database connections, table structure, and critical data