View Single Post
Old 06-04-2005, 05:10:09 PM     #6 (permalink)
mishmash

 
Join Date: Jan 2005
Posts: 160
mishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond reputemishmash has a reputation beyond repute

Use .htaccess

For efficiency you might want to look into using .htaccess

In which you could obtain the refering domain using:
%{HTTP_referer}
If you have a separate .html file for each domain you could do something like:

Code:
RewriteEngine On
RewriteCond %{HTTP_REFERER} ^http:[^.]+.([^.]+).co.uk/ 
RewriteRule /* http://www.domain.com/$1.html
Or depending on what you're doing something like:

Code:
RewriteEngine On
RewriteCond %{HTTP_REFERER} ^http:[^.]+.([^.]+).co.uk/ 
RewriteRule /* http://www.domain.com/parked.php?domain=$1

I've not tested the above but I know the idea works, the apache docs on this are:
http://httpd.apache.org/docs/mod/mod_rewrite.html
mishmash is offline