ravi181229 Posted July 14, 2008 Share Posted July 14, 2008 Hi, I am using Google Contacts Data API to retrieve Single user contact. I am getting the response as: <html><head><title type="text">Sourin</title><link rel="http://schemas.google.com/contacts/2008/rel#edit-photo" type="image/*" href="http://www.google.com/m8/feeds/photos/media/ravirkkm%40gmail.com/2/1B2M2Y8AsgTpgAmY7PhCfg"><link rel="self" type="application/atom+xml" href="http://www.google.com/m8/feeds/contacts/ravi%40gmail.com/full/2"><link rel="edit" type="application/atom+xml" href="http://www.google.com/m8/feeds/contacts/ravi%40gmail.com/full/2/1215717176946000"></head><body>object(Zend_Http_Response)#6 (5) { ["version:protected"]=> string(3) "1.1" ["code:protected"]=> int(200) ["message:protected"]=> string(2) "OK" ["headers:protected"]=> array( { ["Content-type"]=> string(35) "application/atom+xml; charset=UTF-8" ["Cache-control"]=> string(35) "max-age=0, must-revalidate, private" ["Gdata-version"]=> string(3) "1.0" ["Last-modified"]=> string(29) "Thu, 10 Jul 2008 19:12:56 GMT" ["Transfer-encoding"]=> string(7) "chunked" ["Date"]=> string(29) "Mon, 14 Jul 2008 16:04:14 GMT" ["Server"]=> string(7) "GFE/1.3" ["Connection"]=> string(5) "Close" } ["body:protected"]=> string(1652) "668 <entry xmlns="http://www.w3.org/2005/Atom" xmlns:gcontact="http://schemas.google.com/contact/2008" xmlns:batch="http://schemas.google.com/gdata/batch" xmlns:gd="http://schemas.google.com/g/2005"><id>http://www.google.com/m8/feeds/contacts/ravi%40gmail.com/base/2</id><updated>2008-07-10T19:12:56.946Z</updated><category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/contact/2008#contact"><content type="text">A good Developer.</content><gd:organization rel="http://schemas.google.com/g/2005#other"><gd:orgname>Brickwork India</gd:orgname><gd:orgtitle>Sou</gd:orgtitle></gd:organization><gd:email rel="http://schemas.google.com/g/2005#other" address="sourin@gmail.com" primary="true"><gd:im address="sourin" label="CUSTOM" protocol="http://schemas.google.com/g/2005#YAHOO"><gd:phonenumber rel="http://schemas.google.com/g/2005#mobile">9886388929</gd:phonenumber><gd:postaladdress rel="http://schemas.google.com/g/2005#home">BTM 1st Stage</gd:postaladdress><gcontact:groupmembershipinfo deleted="false" href="http://www.google.com/m8/feeds/groups/ravir%40gmail.com/base/2710"></gcontact:groupmembershipinfo> 0 " } </gd:im></gd:email></category></entry></body></html> How do I read this and display user info? Thanks. Quote Link to comment Share on other sites More sharing options...
ravi181229 Posted July 15, 2008 Author Share Posted July 15, 2008 I got solution. need to use getEntry() funtion. $gdata = new Zend_Gdata($client); $feed = $gdata->getEntry('http://www.google.com/mate/feeds/contacts/emailid%40gmail.com/full/2'); echo $feed->id; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.