# TODO redirect based on language settings
# and the presence of the forum
# for locale redirection
Include conf/vhosts.d/forums.d/*.conf
# using Redirect create a loop, so we use mod_rewrite here
RewriteEngine On
RewriteRule ^/$ /en/ [R]
RewriteRule ^/(..)$ /$1/ [R]
AliasMatch ^/(..)/(.*) <%= forums_dir %>/$1/phpBB/$2
/.*/phpBB/">
Allow from all
<%-
forbidden = ['install',
'cache',
'includes',
'phpbb_seo/includes',
'store',
'images/avatars/upload',
'files',
'umil/error_files',
'gym_sitemaps/acp',
'gym_sitemaps/sources',
'gym_sitemaps/cache',
'gym_sitemaps/includes',
'gym_sitemaps/display',
'gym_sitemaps/modules',
]
for f in forbidden
-%>
/.*/phpBB/<%= f %>/ >
Order Allow,Deny
Deny from all
<%- end -%>