Código:
necesito recoger los valores id, secret y title.<?xml version="1.0" encoding="utf-8" ?> - <rsp stat="ok"> - <photos page="1" pages="1" perpage="100" total="6"> <photo id="3841560991" owner="41424175@N07" secret="4f9afa3a3d" server="2527" farm="3" title="adsd" ispublic="1" isfriend="0" isfamily="0" /> <photo id="3841559313" owner="41424175@N07" secret="091ba9537a" server="2597" farm="3" title="dd" ispublic="1" isfriend="0" isfamily="0" /> <photo id="3841549609" owner="41424175@N07" secret="e40803948d" server="2546" farm="3" title="pez" ispublic="1" isfriend="0" isfamily="0" /> <photo id="3829328283" owner="41424175@N07" secret="7603e7bfe2" server="2612" farm="3" title="phpNM4tqo" ispublic="1" isfriend="0" isfamily="0" /> <photo id="3830100746" owner="41424175@N07" secret="150fbea3d9" server="2629" farm="3" title="phpSPyE0A" ispublic="1" isfriend="0" isfamily="0" /> <photo id="3820317964" owner="41424175@N07" secret="7799b6fb52" server="2455" farm="3" title="phpbsdLxp" ispublic="1" isfriend="0" isfamily="0" /> </photos> </rsp>
¿Alguien podria ayudarme a hacerlo? con la función simplexml_load_file seria algo similar a esto
Código PHP:
$xml = simplexml_load_file("http://flickr.com/services/rest/?method=flickr.people.getPublicPhotos&user_id=&id&api_key=$apikey");
for ($k=0; $k<$imageNum; $k++) {
$i = $k;
<a href="<?php
echo "http://static.flickr.com/";
echo $xml->photos->photo[$i]['server'];
echo "/";
echo $xml->photos->photo[$i]['id'];
echo "_";
echo $xml->photos->photo[$i]['secret'];
echo "_m.jpg";
?>"</a>
Muchas gracias