Redirect referral link

R

Roland

Hello,

Is it possible to transfer a redirected link to a sub page on my website?

Example:

www.mydomain.com -----> Page with webhosting

www.my2domain.com ----> directly points to www.mydomain.com

When people come from my2domain.com the must be directly reffered to a
subpage instead of the standard homepage.

Note: The won't come there by pressing a link but are directly being
directed by a domainpointer.

Greetz Roland.
 
I

Ivo

Roland said:
Hello,

Is it possible to transfer a redirected link to a sub page on my website?

Example:

www.mydomain.com -----> Page with webhosting

www.my2domain.com ----> directly points to www.mydomain.com

When people come from my2domain.com the must be directly reffered to a
subpage instead of the standard homepage.

Note: The won't come there by pressing a link but are directly being
directed by a domainpointer.

Greetz Roland.

Sure, just see what value is stored in the variable
window.document.referrer. For example:
if (document.referrer.indexOf('my2domain')>-1)
location.replace('subpage.htm');
If you can, you should do this on the serverside to minimize unnecessary
webtraffic. Your users don't need to notice they are being rerouted.
Also, the referer variable may be empty if they surf in from a javascripted
link, or from their Favorites menu.
HTH
Ivo
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,012
Latest member
RoxanneDzm

Latest Threads

Top