Retrieve Facebook Likes Count with PHP

You can get the total number of likes and share count of any web URL with a little bit of PHP and FQL (Facebook Query Language).

You don’t have to fiddle with the Facebook SDK or the API and this trick works for both Facebook pages as well as any external web page that has the like button or has been shared on Facebook.