View Single Post
Old 12-17-2009, 06:00 AM   #7
evanmaastrigt
Connoisseur
evanmaastrigt doesn't litterevanmaastrigt doesn't litter
 
Posts: 78
Karma: 192
Join Date: Nov 2009
Device: Sony PRS-600
Quote:
Originally Posted by horsegoalie View Post
If you go to that link, the Globe will strip the ?mode=PF off the back end, leaving you with:
http://www.boston.com/business/ticke...merica_24.html
If you click on the print icon on the web page, it will bring you back to the link I originally wanted to use. Any ideas how to work around this?
They are looking at the Referer header. If it is not set to the URL of the original page you do not get the print version. I set that header with Tamper Data on FireFox and got to the print version alright.

So adding that header in the browser's request might work but I can not find how to do that in the docs for Mechanize.
evanmaastrigt is offline   Reply With Quote