polipi
Сообщений: 2
Оценки: 0
Присоединился: 2011-02-21 13:14:31.326666
|
здравствуйте, подскажите есть сайт xml http://xml.xxx.net внутри ссылки вида <ci><![CDATA[http://xxx.com/dd/?c=vLZjn2xgVKiDZO]]></ci> мне надо получить http://xxx.com/dd/?c=vLZjn2xgVKiDZO как мне их спарсить? делал так <?php //Get the XML document loaded into a variable $ch = curl_init("http://xml.xxx.net"); curl_setopt($ch, CURLOPT_HEADER, 0); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); $xml = curl_exec($ch); curl_close($ch); preg_match('/<ci(.*)?>(.*)?<\/ci>/', $xml, $match); $result=$match[1]; echo $result; print_r($match); ?> не помогло,помогите
|