/ Published in: PHP
Also check out...
http://roshanbh.com.np/2008/10/creating-parsing-json-data-php.html
http://roshanbh.com.np/2008/10/creating-parsing-json-data-php.html
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
$yelpstring = file_get_contents("http://api.yelp.com/business_review_search?category=bars&lat=".$latitude."&long=".$longitude."&radius=25&num_biz_requested=100&ywsid=<your yelp account id>", true); foreach($obj->businesses as $business): echo "<img border=0 src='".$business->photo_url."'><br/>"; echo $business->name."<br/>"; echo $business->address1."<br/>"; if( $business->address2 ){ echo $business->address2."<br/>"; }; echo $business->city ."<br/>"; echo $business->state ."<br/>"; echo $business->zip ."<br/>"; echo $business->latitude ."<br/>"; echo $business->longitude ."<br/>"; echo "<hr>"; endforeach;
URL: http://groups.google.com/group/yelp-developer-support/browse_thread/thread/d52aa7033b3e7dbd#