|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
|
Re: [PLUG] URL redirects in apache
|
On Wed, 23 Jul 2003, Marc Zucchelli wrote:
> For the sample URL
> http://www.domain.com/path/to/random/url, I would like
> for apache to redirect that to the same exact URL but
> without the www, is this possible from httpd.conf or
> better yet, .htaccess?
It's fairly simple in httpd.conf. For example, this is a paragraph from my
httpd.conf:
# stuff that gets redirected to marnanel.org
<VirtualHost 193.201.200.145>
ServerName www.marnanel.org
Redirect permanent / http://marnanel.org/
</VirtualHost>
The redirect of "/" applies to everything under /, too. So not only does
http://www.marnanel.org -> http://marnanel.org , but
http://www.marnanel.org/unexpected-bath.html ->
http://marnanel.org/unexpected-bath.html .
T
--
thomas thurman - marnanel at marnanel dot org - http://marnanel.org
The walls are frozen rivers of orange stone.
_________________________________________________________________________
Philadelphia Linux Users Group -- http://www.phillylinux.org
Announcements - http://lists.netisland.net/mailman/listinfo/plug-announce
General Discussion -- http://lists.netisland.net/mailman/listinfo/plug
|
|