PDA

View Full Version : Rewrite URL In apache2


Alam
24th December 2007, 21:44
Hello All,

I am using ISPConfig on ubuntu gusty with apache2,squirrelmail installed as an addon in ispconfig, I need some help please with URL rewrite. If I can I would like to avoid adding a co-domain in ispconfig no specific reason thats the way I want it to be.

At the minute to access my webmail I have to do this

https://www.abc.co.uk:81/squirrelmail and that redirects to https://www.abc.co.uk:81/src/login.php

but what i want it to redirect it to (through apache2)

https://www.abc.co.uk/webmail.

Also I want it done once, I do not want to it for every domain on my server, hence other customers if they want to access there webmail simply type https:// theredomain.name/webmail and through to there webmail from there.

I have read about it on different webites, forums including apache and this (seems quite an old thread here) but have not been able to solve the mystery.

I cannot understand how it is done it seems hard.

Any help on this with examples would be really appreciated.

Thank you very much in advance. Looking forward for positive response.
:)

mccharlet
25th December 2007, 12:06
I have redirected http://all_domain/webmail to https://domain:81/squirrelmail

I have add in the file /etc/apache2/sites-enabled/000-default

Redirect /webmail https://domain:81/squirrelmail/

Alam
25th December 2007, 14:32
I have redirected http://all_domain/webmail to https://domain:81/squirrelmail

I have add in the file /etc/apache2/sites-enabled/000-default

Redirect /webmail https://domain:81/squirrelmail/
Hi

Thank you very much for the reply I tried but did'nt work, just a quick one did you add the line before virtual host or between virtual host also sorry if it sounds stupid do u replaced domain with real domain name

mccharlet
25th December 2007, 15:57
are you restarted apache2?

Alam
25th December 2007, 19:11
are you restarted apache2?
Hi

Thankyou very much for your support that worked :) for me. You are a star