# ========================================
# .htaccess - Development Mode (Simplified)
# ========================================
# Enable Rewrite Engine
RewriteEngine On
RewriteBase /
# ========================================
# URL Routing
# ========================================
# Redirect shop/* to backend/public/*
RewriteRule ^shop/?$ backend/public/index.php [L]
RewriteRule ^shop/(.*)$ backend/public/$1 [L]
# Redirect dashboard/* to backend/admin/*
RewriteRule ^dashboard/?$ backend/admin/dashboard.php [L]
RewriteRule ^dashboard/(.*)$ backend/admin/$1 [L]
# Redirect api/* to backend/api/*
RewriteRule ^api/(.*)$ backend/api/$1 [L]
# ========================================
# Basic Settings
# ========================================
# Disable directory browsing
Options -Indexes
# ========================================
# PHP Settings
# ========================================
php_flag display_errors On
php_flag log_errors On
# File upload limits
php_value upload_max_filesize 50M
php_value post_max_size 50M
php_value max_execution_time 300
php_value memory_limit 256M
# ========================================
# Compression
# ========================================
AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css text/javascript application/javascript application/json
# ========================================
# Caching
# ========================================
ExpiresActive On
ExpiresByType image/jpg "access plus 1 year"
ExpiresByType image/jpeg "access plus 1 year"
ExpiresByType image/gif "access plus 1 year"
ExpiresByType image/png "access plus 1 year"
ExpiresByType image/webp "access plus 1 year"
ExpiresByType text/css "access plus 1 month"
ExpiresByType application/javascript "access plus 1 month"
# ========================================
# End of .htaccess
# ========================================