से सामग्री प्रकार जाओ इस शीर्ष लेखcURL
$imageurl = "http://p.twimg.com/AW2-vIUCAAE_1FN.png";
$ch = curl_init();
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt ($ch, CURLOPT_URL, $image_url);
curl_setopt ($ch, CURLOPT_CONNECTTIMEOUT, 20);
curl_setopt ($ch, CURLOPT_USERAGENT, $_SERVER['HTTP_USER_AGENT']);
curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_HEADER, true);
curl_setopt($ch, CURLOPT_NOBODY, true);
$content = curl_exec ($ch);
curl_close ($ch);
print_r($content);
HTTP/1.1 200 OK
Server: nginx
X-peep-host: den2twapi014
Last-Modified: Mon, 15 Aug 2011 03:41:50 GMT
ETag: "7283847-dbb8-4aa830b1dabf0"
Accept-Ranges: bytes
Content-Length: 56248
Cache-Control: public, max-age=21600
Expires: Wed, 28 Mar 2012 15:53:57 GMT
Content-Type: image/png
X-CDN: AKAM
Date: Wed, 28 Mar 2012 09:53:57 GMT
Connection: keep-alive
क्या Content-Type:
बाहर प्रतिध्वनित करने के लिए सबसे अच्छा तरीका है लौटने पाने के लिए महान काम करता है?
धन्यवाद! क्या आपको पता है कि वैध सामग्री प्रकारों की एक सूची है, मुख्य रूप से छवियों के लिए, लेकिन उन सभी को जानना अच्छा होगा। – daidai
इसे मिला http://en.wikipedia.org/wiki/Mime_type – daidai