Sorting by facebook likes
duhol Offline
Junior Member
**
Posts: 34
Joined: Mar 2011
Post: #1
Toungue Sorting by facebook likes
Hi

I write about my problem at this forum because there are two specialists who help me Winktongue

Well, it about facebook like, again

What did I do until now.
1. I create row in table mybb_threads in database called "fblikes" same as "views".
2. Php code shows me number of likes in thread:

PHP Code:
$source_url[] = "http://www.sentens.pl/showthread.php?tid={$tid}";
$url = "http://api.facebook.com/restserver.php?method=links.getStats&urls=".implode( ',', $source_url );
$xml = file_get_contents($url);
$xml = simplexml_load_string($xml);
$totals = $xml->link_stat->total_count;

where $totals is requested number of likes.

And now. What is need to do to write number $totals into database cell "fblikes"?



Only thing that I dont know how to do is write $totals into database.
Or there is a way to use xthreads???

So, PHP Gurus, will you help? Smile

(This post was last modified: 10-13-2011 07:21 AM by duhol.)
10-13-2011 06:03 AM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

Messages In This Thread
Sorting by facebook likes - duhol - 10-13-2011 06:03 AM
RE: Sorting by facebook likes - duhol - 10-13-2011, 01:06 PM
RE: Sorting by facebook likes - duhol - 10-14-2011, 09:27 AM
RE: Sorting by facebook likes - duhol - 10-15-2011, 07:34 PM
RE: Sorting by facebook likes - duhol - 10-16-2011, 05:05 AM
RE: Sorting by facebook likes - duhol - 10-16-2011, 06:01 AM
RE: Sorting by facebook likes - duhol - 10-16-2011, 08:58 PM

 Standard Tools
Forum Jump: