I have a domain example.com
with the following DNS records:
Hostname Type Value
example.com A 93.184.216.34
help.example.com A 93.184.216.34
www.example.com A 93.184.216.34
The file /etc/httpd/sites-available/example.com.conf` is:
<VirtualHost *:80>
ServerAdmin admin@mydomain.com
ServerName example.com
ServerAlias www.example.com help.example.com
DocumentRoot /var/www/html/example.com/_site
</VirtualHost>
When accessing help.example.com
or www.example.com
in the browser, they both get redirected to example.com
. I'd like help.example.com
to be redirected to example.com/help
while still keeping help.example.com
in the browser address bar. How to make such redirection?
Aucun commentaire:
Enregistrer un commentaire