Home › Forums › Other › Remove .php extension from subdomain URLs? › Reply To: Remove .php extension from subdomain URLs?
August 6, 2013 at 1:53 am
#145787
asiek
Participant
@traq If I am understanding correctly…then yes I do.
Full .htaccess file//
RewriteEngine on
RewriteCond %{HTTP_HOST} ^test\.example\.com$ [OR]
RewriteCond %{HTTP_HOST} ^www\.test\.example\.com$
RewriteRule ^/?$ "http\:\/\/example\.com\/test" [R=301,L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^([^\.]+)/$ $1.php