How to Count All Your Facebook Friends using Facebook Garph API with PHP SDK


How to Count All Your Facebook Friends using Facebook Garph API with PHP SDK?

Hello and welcome on the Facebook Graph API with PHP SDK Tutorial blog, On this blog i will teach you how to access the facebook app user's info in your custom app with Facebook Graph API using PHP SDK like User's Name, Profile Pic, Latest Post, Likes etc.

In this tutorial i will tell you how to count all friends and display the final count on your app, here is a simple code to access all friends and then count them and display the final count...

The below example is a complete code to access your all friends and count them...



 $app_id,
'secret' => $app_secret,
'cookie' => true
));

$user = $fb->getUser();
$loginUrl = $fb->getLoginUrl(array
(
'scope' => 'email'
)
);

if ($user)
{
try
{
$fbuser=$fb->api('/me/friends');
$access_token = $fb->getAccessToken();
} catch (FacebookApiException $e)
{
echo $e;
$user = null;
}
}

if (!$user) {
echo "<script type="text/javascript">top.location.href = '$loginUrl';</script>";
exit;
}
$friend_count=0;
foreach($fbuser['data'] as $friends)
{
$friends_count++;

}

echo "You have Total ".$friend_count." Friends on Facebook";

?>

Now copy the above code and paste it to your app and get the all friends count in your app...

Learn Facebook App Development Free 

How to Display Female Friends List only using Facebook Graph API


This tutorial is based on the Facebook Apps development. I have found there are very few tutorials on Facebook Apps development so i decided to give the series of Facebook Apps Tutorials here.

In this tutorial i am teach you that How to access  female friends only and display them using Facebook Graph API with PHP sdk......

The Code for accessing and displaying the Female friends only is shown below....

Learn How to Create Facebook App

Learn How to Get App ID and App Secret



<html>

<body>
<?php

$app_id = "YOUR APP ID";
$app_secret = "YOUR APP SECRET";

try
{
include_once ('libs/facebook.php');
}
catch(Exception $o)
{
print_r($o);
}

$fb = new Facebook(array(
'appId' => $app_id,
'secret' => $app_secret,
'cookie' => true
));

$user = $fb->getUser();
$loginUrl = $fb->getLoginUrl(array
(
'scope' => 'email'
)
);

if ($user)
{
try
{
$fbuser=$fb->api('/me/friends?fields=id,name,gender');
$access_token = $fb->getAccessToken();
} catch (FacebookApiException $e)
{
echo $e;
$user = null;
}
}

if (!$user) {
echo "<script type='text/javascript'>top.location.href = '$loginUrl';</script>";
exit;
}
$count=0;$Mcount=0;
foreach($fbuser['data'] as $friends){

if($friends['gender']=="famale")
{
$Mcount++;
echo $friends['name']."<img src='https://graph.facebook.com/";.$friends['id']."/picture' width='50' height='50' /><br/>";
}
}

echo "Female Friends Count=".$Mcount;

?>
</body&gt
</html>

To get AppId and secret you have to create an App using your Facebook account...

Learn How To Create a Facebook App

How to Upgrade to Windows 8.1 From Windows 8?

Windows 8 users who�ve been looking forward to an improved user expertise don�t have to wait from now on. Microsoft�s Windows 8.1 is accessible as a free upgrade for any computer running Windows 8. With simply very easy steps, you'll get necessary new features, as well as the power to see multiple windows in modem UI, a start Button and a search perform that returns results each from the net and your hard drive. Here�s a way to upgrade your Windows 8 to Windows 8.1

(1) Check that your computer has all recent Windows updates. If you�ve been victimization Windows 8 steady you're in all probability up to this point, however if it's been many days since you last logged in to your computer, follow these steps to examine.


  •  Click "settings" on the Charms menu.





  •  Click on "Change PC Settings".






  •  Now click on "Windows Update"






  •  Click on "Check for Updates Now" button to examine if there square measure any new files. Check for updates currently






  •  Force any updates to put in forthwith by clicking on the �We�ll install____ automatically� link then Install.





(2) Open the Windows Store app.




(3) Click the "Update to Windows 8.1 for free" button. If you can't find this button on the screen, check for updates once more, shut and open up the Windows Store or bring up your machine.



(4) Click the "Download" button.




You may have to wait half-hour or more for the install to transfer, however you'll keep victimization your computer throughout this point.



(5) Click "Restart Now" when ask.



Your computer can then take many minutes putting in Windows 8.1, complete with a minimum of one bring up. you'll go away from your computer and do one thing else for five minutes or a lot of as a result of your input won�t be needed for a jiffy.

(6)Click �I Accept� when License terms come on screen.




(7) Click "Use express Settings" at all-time low of the screen. you'll conjointly select custom settings, however we discover the categorical settings work well for many users.




(8) Sign in to Windows as you ordinarily would.




(9) Enable Windows to send a security code to your phone if it prompts you. you'll skip this step, however might not be ready to synchronise your account across computers while not performing it later.




(10) Enter the code you received.




(11) Click Next on the Skydrive screen.




Now wait for few minutes. You�ll see some messages on the screen that say it's setting up and installing apps.




After another number of minutes, the Windows 8.1 begin screen can seem and you�ll be able to go.

You like this article then please share this article to your friends and appreciate me by your comment :)

BBM for Android and iOS launched Officialy

After Long waiting, Finally Blackberry launched BBM for Android and iOS now.

The initial launch date of BBM for android and iPhone devices came and went. the corporate claimed that earlier leaked versions of the app had caused internal issues, that resulted in the delay. A month after the initial launch date, BlackBerry on Monday declared the supply of BBM within the Google Play store and Apple's App Store.

This App is also available on BBM.com and Samsung App Store.




The Process to start BBM on your Android or IPhone  is very easy. After download and install this App, you have to create BBID, if you have already then use it.

To creat BBID go to www.blackberry.com/blackberryid


To download BBM, it require  iOS 6 or above for apple and Android 4.0 or above on Android.

I heard news that BBM will not restricted only for Android or iOS, its will be available for windows also. well we have to wait for BBM on windows. till then enjoy BBM on Android and iOS.

How to split string on the basis of serial number in C#

Some times we have a string which has the some points with different serial numbers like this...

1.Good Team Player, Fast Learner and a Hard. 2. Worker.Organised and Well Structured at Work. 3. Committed to deadlines and Schedules. 4.Honest, Sincere with high level of Integrity.

and we have to split the string as like this....

1.Good Team Player, Fast Learner and a Hard. 
2. Worker.Organised and Well Structured at Work. 
3. Committed to deadlines and Schedules. 
4.Honest, Sincere with high level of Integrity.

so here is a simple code to split it using c#



string s = "1.Good Team Player, Fast Learner and a Hard. 2. Worker.Organised and Well Structured at Work. 3. Committed to deadlines and Schedules. 4.Honest, Sincere with high level of Integrity.
";
int count=0;
string s1 = "";
for(int i=0;i<s.Length;i++)
{
if (Char.IsNumber(s[i])&&s[i + 1] == '.')
{
s1 = "";
for (int k =i ; k < s.Length; k++)
{

s1 += s[k];
if(k<s.Length-1)
{
if (Char.IsNumber(s[k+1]) && s[k + 2] == '.')
break;
}
count++;
}
Response.WriteLine(s1);
i = count;
}


}
}

Now you will have the result as like you want...

Nokia Lumia 1520 : Top Features

Nokia Lumia 1520

Nokia eventually introduced it's highly-anticipated Nokia Lumia 1520 phablet at Nokia world in Abu Dhabi, amongst a lot fanfare. As the most recent Lumia 1520 does not look a lot totally different from it's other Lumia bros regarding layout, this includes several brand new features. This Finnish device producer features presented a bevy of increased components technical specs as well as better apps for the Lumia 1520. Listed here are the very best features of the actual Nokia Lumia 1520.

HD Display:
The actual identify of the Nokia's newest phablet will be the full-HD present. Nokia Lumia 1520 is the first windows with 1080p HIGH DEFINITION resolution.


Nokia lumia 1520

The three-column large live tiles:
The actual three-column view has got the benefit associated with bringing additional symbols to the screen, which means less scrolling available for you, especially when an individual utilize tiniest tiles. You can also realize that additional e-mails along with images fill up the screen, another fringe good thing about upsizing.

Quad-core Qualcomm Snapdragon 800 processor
The product features a 2.2GHz quad-core Qualcomm Snapdragon 800 processor in addition to gets the primary Microsoft windows Phone being supported by the quad-core processor.

Nokia Beamer App:
Nokia has additionally introduced a brand new Nokia Beamer app on the Lumia 1520 that permits users to share content to any HTML5 enabled device. Users will share contents like pictures, documents, location details and even camera optical device from the Lumia 1520 to any compatible screen through social media, emails and SMS.

Storyteller App:
Nokia's new Storyteller feature organizes clicked pictures into stories with written record order exploitation HERE location details. Users also can check for details and reviews of a location on HERE map exploitation the Storyteller app. The app has additionally been introduced on Lumia 1320 and Lumia 2520 tablet.

Camera App:
Nokia introduces a camera app known as Refocus, that works just like the Lytro camera to shift focus when you are taking an attempt.

Nokia's new Nokia Camera app combines 2 common apps, the Nokia professional Cam and Nokia good Cam into one app. The new Nokia Camera app brings new writing and sharing options to the Lumia 1520. The Nokia Camera app includes new camera algorithms and comes with a replacement feature dubbed color pop. It conjointly sports a sensible mode which may shoot variety of pictures during a moment and permits removing reserve objects kind the pictures.

New firmware - Lumia Black:
the company announced that it's performing on updated firmware dubbed Lumia Black. The Lumia 1520 and Lumia 1320 are presently the sole devices to feature the new firmware.

List of Android Phones which will get Android 4.4 KitKat Firmware Update

Android operating system 4.4 Kitkat which was lately released. Google might launch with Nexus 5 in a short time and here we have the record of mobile phones which will get an firmware upgrade of Android 4.4 KitKat. The upgrade will be made the decision by the cellular producers according to the cell mobile phones components configurations.


Android 4.4 KitKat


LG Mobiles

LG G2
LG Nexus 4
LG Optimus L7, L5, L3
LG Optimus G
LG Optimus G Pro
LG Optimus VU

Samsung Mobiles

Samsung Universe S4
Samsung Universe S4 Zoom
Samsung Universe S4 Active
Samsung Universe Observe 3
Samsung Universe Super (no verification whether the 5.8, 6.3 or both)
Samsung Universe S3
Samsung Universe Observe II
Samsung Universe S4 Mini
Samsung Universe Tab 3 & Tab 2

HTC Mobiles

HTC One
HTC One X+
HTC One X
HTC Wish 600 and other Wish sequence mobile phones released in 2013
HTC Android DNA
HTC J
HTC Butterfly S

Sony Mobiles

Sony Xperia Z1
Sony Xperia Z
Sony Xperia Z Ultra
Sony Xperia Product Z
Sony Xperia Product S

Xperia Z1 has not got an upgrade for Android operating system 4.3 and is still operating on Android operating system 4.2 Jelly Bean  So  now Sony models might take an immediate leap to the newest edition of Android operating system 4.4 Kitkat or might go in the transaction.

Just keep verifying for an upgrade very regularly. You might get skip the notice so just go to Settings and examine for an Update to have the new Android operating system 4.4 KitKat which allows you a lot relaxed using Android operating system.

Recent Comments