urllib redirect

Thomas thomas at madeforchina.com
Tue Apr 18 00:59:31 EDT 2000


I've got a pretty tame question.

I want one of my functions to redirect the URL.  
(ie I call the script and off I go to www.spam.com)

So, here's what I get, and have not overcome yet:

import urllib
def simpleredirect() :
    ############
     print "Content-type: text/html"
     print urllib.urlopen('http://www.spam.com').read()

simpleredirect()

TIA,
Tom





More information about the Python-list mailing list