Rewrite URL in apache
Hi all, can i ask for your help? I'm in trouble in setting up my vhost in apache. Currently my site is up and running, my problem is that I can't get it to short url. Here's the scenario:
a. I have a website running on my server currently on vhost on port 80 and 443. Here is the config file: Code:
<VirtualHost *:80> Code:
RewriteRule ^/view/Special:UserLogin(.*) https://wiki.company.com/ [R,L] |
Hi,
Quote:
Quote:
Regards |
you can add an alias entry for view/Special:UserLogin
Code:
Alias / view/Special:UserLogin Code:
Alias /login view/Special:UserLogin |
Quote:
Alias is used to map a directory outside the DocumentRoot to some URL. In this case Special:UserLogin surely does not look like a directory name, so you cannot alias it to something else. |
bathory pointed out the issue,
adding a Rewrite Condition before the ambiguous Rewrite Rule will solve the issue. Quote:
|
All times are GMT -5. The time now is 04:37 PM. |