Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > urllib http status codes

Reply
Thread Tools

urllib http status codes

 
 
Alvin A. Delagon
Guest
Posts: n/a
 
      12-29-2005
Greetings!

Is there any way I can obtain the HTTP status codes when using the
urllib module? As of now I can only think of doing a regex on the
result of the read(). Thanks in advance! ^_^
 
Reply With Quote
 
 
 
 
Kent Johnson
Guest
Posts: n/a
 
      12-29-2005
Alvin A. Delagon wrote:
> Greetings!
>
> Is there any way I can obtain the HTTP status codes when using the
> urllib module? As of now I can only think of doing a regex on the
> result of the read(). Thanks in advance! ^_^


If you connect with httplib you get the status code directly from the
response object.

Kent
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
2to3 urllib.URLopener -> urllib.request.URLopener Chris McDonald Python 0 11-01-2010 11:23 AM
Asynchronous urllib (urllib+asyncore)? Jonathan Gardner Python 1 02-27-2008 12:51 AM
Virtual Key Codes, Scan Codes and ASCII Codes in C gj_williams2000@yahoo.co.uk C Programming 2 08-20-2005 11:04 AM
constants for http status codes Andy Fish ASP .Net 6 03-04-2005 04:01 PM
urllib: http error codes Patrick Useldinger Python 1 12-18-2003 09:02 PM



Advertisments