Welcome to WebmasterWorld Guest from 54.146.171.44

Forum Moderators: ergophobe

Message Too Old, No Replies

Prevent direct linking to print-friendly pages?

Some sites link directly to our print pages which have little to no ads.

   
8:44 pm on Nov 25, 2007 (gmt 0)

5+ Year Member



OK. Here is what I am trying to do. I want people who surf directly to our printer-friendly version of our pages to be forwarded to the regular version of that article if they are coming from a domain other than mine. Here is an example:

I want this URL: http://example.com/page.php?page=print

To forward to this URL when directly accessed from a different domain: http://example.com/page.php

I want to only allow viewing the print url when you come from ONLY the hosting domain.

What would be the best way to do this?

[edited by: tedster at 8:52 am (utc) on Nov. 26, 2007]
[edit reason] switch to example.com [/edit]