Source From Here
Question
I need to get the content-type of an internet(intranet) resource not a local file. How can I get the MIME type from a resource behind an UR?
How-To
You can leverage urllib2 packages and retrieve information from HTTPMessage object:
Question
I need to get the content-type of an internet(intranet) resource not a local file. How can I get the MIME type from a resource behind an UR?
How-To
You can leverage urllib2 packages and retrieve information from HTTPMessage object:
沒有留言:
張貼留言