# Custom error pages (no query strings!)
ErrorDocument 404 /mda/static/error404.html
ErrorDocument 403 /mda/static/error403.html
ErrorDocument 500 /mda/static/error500.html

<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /mda/

  # Route static HTML pages to the custom static page handler
  RewriteRule ^static/(.*)\.html$ /mda/local/staticpage/view.php?page=$1&%{QUERY_STRING} [L]

  # Let Moodle handle the rest
  RewriteRule ^index\.php$ - [L]
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule . /mda/index.php [L]
</IfModule>

# Increase input vars for large forms
php_value max_input_vars 5000
