Forum Moderators: phranque
I figure the best way to finally learn is to find relevant applications for use.
Here's my first:
I'd like to redirect requests for my homepage only from a specific referring website to another page on my website transparently.
Legend to understanding my newbie code:
The page I want any redirects from mysite going to - mysite.com/friendsitelandingpage.htm
The site I want to redirect homepage requests from(preferably invisibly
friendsite.com
Here are the couple feeble attempts that I have made thus far:
RewriteCond %{HTTP_REFER} ^www.friendsite.com$ [NC]
RewriteRule ^(.*)$ http: //www.mysite.com/friendsitelandingpage.htm
or something like?
RewriteCond %{HTTP_REFERER} ^http://(www\.)?friendsite\.com/
RewriteRule .*\.$ [mysite.com...] [nc]
Neither of these worked...but I really have no idea...just didn't want folks to think I'm looking to have "my homework done"...really attempting to UNDERSTAND this better, and this is just my first lesson I guess.
Again, my apologies for my cluelessness...but figure I gotta jump in and be a complete newb at some point if I really wanna learn this correctly.
Any learning materials are certainly appreciated as well. I'm interested mainly in referer redirection and and selectively delivering of content, and looking to ease the learning curve, but wrap my mind around the principles through learning by example as well.