Redirection from www.example.org ,www.example.net and www.exammple.com to www.example.com

2 views
Skip to first unread message

mahesh

unread,
Nov 20, 2009, 1:54:35 AM11/20/09
to UrlRewrite
Hi,

I want redirection from www.example.org ,www.example.net and www.exammple.com
to www.example.com
www.example.org ---> www.example.com
www.example.net ---> www.example.com
www.exammple.com ---> www.example.com


we tried to to write the rules in the urlrewrite.xml but it didn't
work because this we need to implement in the HTTP server(web server)
rather than implementing in the application server.

so we tried to write the entries in the httpd.conf file in IBM http
server.

RewriteEngine on
RewriteRule ^www.example.org http://www.example.com/
RewriteRule ^www.example.net http://www.example.com/
RewriteRule ^www.exammple.com http://www.example.com/

but this also not to working for me.

Please let me know the suggestions.

Regards,
Mahesh.
Message has been deleted
Message has been deleted

mahesh

unread,
Nov 23, 2009, 12:28:51 AM11/23/09
to UrlRewrite
Hi All,

Can you please respond to the above one.

Regards,
Mahesh.

On Nov 20, 11:54 am, mahesh <hariprasad.kanamarlap...@gmail.com>
wrote:
> Hi,
>
> I want redirection fromwww.example.org,www.example.netandwww.exammple.com
> towww.example.comwww.example.org      --->www.example.comwww.example.net      --->www.example.comwww.exammple.com    --->www.example.com
>
> we tried to to write the rules in the urlrewrite.xml but it didn't
> work because this we need to implement in the HTTP server(web server)
> rather than implementing in the application server.
>
> so we tried to write the entries in the httpd.conf file  in IBM http
> server.
>
> RewriteEngine on
> RewriteRule   ^www.example.orghttp://www.example.com/
> RewriteRule   ^www.example.nethttp://www.example.com/
> RewriteRule   ^www.exammple.comhttp://www.example.com/

Avlesh Singh

unread,
Nov 23, 2009, 12:33:53 AM11/23/09
to urlre...@googlegroups.com
Quick answer -
RewriteCond %{REMOTE_HOST}  ^host1.*  [OR]
RewriteCond %{REMOTE_HOST}  ^host2.*  [OR]
RewriteCond %{REMOTE_HOST}  ^host3.*
RewriteRule ...some special stuff for any of these hosts...

Detailed guide -
http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html#rewritecond

Cheers
Avlesh
Reply all
Reply to author
Forward
0 new messages