You are here: Re: help on using curl « PHP Programming Language « IT news, forums, messages
Re: help on using curl

Posted by shotokan99 on 07/03/07 02:53

how to write a callback function that will simply get a custom field
from the header? if i run this code:
$ch = curl_init();
$timeout = 0;
curl_setopt ($ch, CURLOPT_URL, $xmyurl);
curl_setopt($ch, CURLOPT_HEADER, 1);

ob_start();
curl_exec($ch);
$s=ob_get_contents();
echo var_dump($s);

i get this result:
string(712) "HTTP/1.1 200 OK Server: Apache-Coyote/1.1 Content-
Disposition: attachment; filename=5abe325176661.png ...."

now there are part of the string that i wanted to take..perhaps i can
use strpos,preg_match...etc.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация