Solved

Url rewriting

Posted on 2006-07-17
5
235 Views
Last Modified: 2010-03-04
0
Comment
Question by:us111
  • 2
  • 2
5 Comments
 
LVL 27

Expert Comment

by:caterham_www
ID: 17125252
it depends...

If http://mail.mydomain.com is a separate account, you could use in a .htaccess file (if you don't have access to the configuration files)

Redirect 301 / http://www.otherdomain.com/othermail/

But if both domains are pointing to the same location, you must use mod_rewrite to check the HTTP_HOST.
0
 
LVL 8

Author Comment

by:us111
ID: 17128443
To be more precised, this is the same server and mod_rewrite is require for this purpose but how....
0
 
LVL 27

Accepted Solution

by:
caterham_www earned 500 total points
ID: 17129465
ok. So you must check the Host. That can be done with a condition.

RewriteCond %{HTTP_HOST} =mail.mydomain.com
RewriteRule ^(.*) http://www.otherdomain.com/othermail/$1 [R=301,L]

that will issue a redirect if the user comes from mail.mydomain.com.
0
 
LVL 8

Author Comment

by:us111
ID: 17129589
ok gonna try tonight
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
MDB2 Error: not found 4 135
local dns 2 115
Utility for identifying files that are different 5 70
Updating PHP in Windows Server 2012 r2 22 77
As Wikipedia explains 'robots.txt' as -- the robot exclusion standard, also known as the Robots Exclusion Protocol or robots.txt protocol, is a convention to prevent cooperating web spiders and other web robots from accessing all or part of a websit…
Hi, in this article I'm going to teach you how to run your own site, and how to let people in (without IP). I'll talk about and explain each step... :) By the way, everything in this Tutorial is completely free and legal. This article is for …
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now