SetEnv PHP_INI_SCAN_DIR /opt/cpanel/ea-php72/root/etc/php.d/:/home/britisht/public_html/ RewriteEngine on RewriteCond %{HTTPS} off RewriteCond %{REQUEST_URI} !^/\.well-known/cpanel-dcv/[0-9a-zA-Z_-]+$ RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$ RewriteRule ^(.*)$ https://www.britishtrolley.org.uk/$1 [R=301,L] RewriteOptions inherit # Don't show directory listings. Options -Indexes # Route requests to Exponent. DirectoryIndex index.php # Various rewrite rules. RewriteEngine On # you may have to edit/uncomment the next line if running eXp from a subfolder # RewriteBase /subfolder-name # if moving eXp from a subfolder to root, edit/uncomment ONLY one of the next 3 lines # Redirect 301 /testfolder http://yourdomain.org/ # RedirectMatch 301 ^/testfolder/$ http://yourdomain.org/ # RewriteRule ^testfolder/(.*)$ /$1 [R=301,NC,L] # To redirect all users to access the site WITH the 'www.' prefix, # (http://example.com/... will be redirected to http://www.example.com/...) # uncomment and adapt the following: # RewriteCond %{HTTP_HOST} ^example\.com$ [NC] # RewriteRule ^(.*)$ http://www.example.com/$1 [L,R=301] # To redirect all users to access the site WITHOUT the 'www.' prefix, # (http://www.example.com/... will be redirected to http://example.com/...) # uncomment and adapt the following: # RewriteCond %{HTTP_HOST} ^www\.example\.com$ [NC] # RewriteRule ^(.*)$ http://example.com/$1 [L,R=301] # the next two lines will dish out .html pages if they exist, which may not be a desired effect! RewriteCond %{REQUEST_URI} !^/\.well-known/cpanel-dcv/[0-9a-zA-Z_-]+$ RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$ RewriteRule ^$ index.html [QSA] RewriteCond %{REQUEST_URI} !^/\.well-known/cpanel-dcv/[0-9a-zA-Z_-]+$ RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$ RewriteRule ^([^.]+)$ $1.html [QSA] # RewriteRule ^login.php$ login/showlogin # Kludge out certain file types that we don't want to try to route thru the eXp router. # Kludge out image files that we don't want to try to route thru the eXp router. # Kludge out media files that we don't want to try to route thru the eXp router. # Kludge out certain other misc files that we don't want to try to route thru the eXp router. # These rules basically state if it isn't an existing file, directory or symlink, route it to index.php RewriteCond %{REQUEST_URI} !\.(css|js|pdf|shtml|htc)$ [NC] RewriteCond %{REQUEST_URI} !\.(jp?g|gif|png|tiff)$ [NC] RewriteCond %{REQUEST_URI} !\.(mp3|mp4|webm|ogv|flv|f4v)$ [NC] RewriteCond %{REQUEST_URI} !^/robots\.txt$ [NC] RewriteCond %{REQUEST_URI} !^/favicon\.ico$ [NC] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-l RewriteCond %{REQUEST_URI} !^/\.well-known/cpanel-dcv/[0-9a-zA-Z_-]+$ RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$ RewriteRule ^(.*)$ index.php [QSA,L] ErrorDocument 403 /index.php?controller=notfound&action=handle_not_authorized&error=403 ErrorDocument 404 /index.php?controller=notfound&action=handle&error=404 ErrorDocument 500 /index.php?controller=notfound&action=handle_internal_error&error=500 RewriteCond %{HTTP_HOST} ^britishtrolley\.org\.uk$ [OR] RewriteCond %{HTTP_HOST} ^www\.britishtrolley\.org\.uk$ RewriteCond %{REQUEST_URI} !^/\.well-known/cpanel-dcv/[0-9a-zA-Z_-]+$ RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$ RewriteRule ^/?$ "https\:\/\/www\.britishtrolley\.org\.uk\/" [R=301,L]