Facebook Login using swift Facebook Integration

swift gift facebook This is a topic that many people are looking for. star-trek-voyager.net is a channel providing useful information about learning, life, digital marketing and online courses …. it will help you have an overview and solid multi-faceted knowledge . Today, star-trek-voyager.net would like to introduce to you Facebook Login using swift Facebook Integration. Following along are instructions in the video below:

“What surprise in this video. I will show you how to log into the facebook facebook using swift as you get you can find a complete link in description i that in the description also you so here is the developers store facebookcom. Will be are going to create our app. So that i have to complicate with our mobile app.

So here you can see the documentation of the complete. How you will add the shift sdk in the project based off other languages. I can say that hplc koh mating with the k. So it does the goethe with first of all tickles.

So we are interested in swift. Here. You can see so if this ticket. Now you can see here the facebook sdk for cert because we can stick a percept allow you to use all the cool facebook sdk and ios api is with include facebook logins a pos graph api so in this project basically we communicate with the facebook and get a profile of user so here you can see the how to register mobile app.

Oh here you can see that list of points created in the background create an apple id and mobile app information. Five steps. The first step. I m going to create a new apple id.

I are already then i hope face it above all already so here you can see that i left. The first step and go to create a new apple id now here. I am. Creating a app on a developer portal.

Is putting the photo. So here is the name of my display name of my facebook demo refer tv here you can see tv s it s believed contact. Email is personal artists. We ll create an apple id.

Mit. And here is a security check and our robot. Like this you. It is the capture so but now with loads and create my fresh project on the facebook button here you can see top fyt and i will basically do the facebook locking setup list of other services.

We can use now i will facebook loaded service. I will use the facebook login service is will see the my apple id i can copy it and set up facebook login take up now here you can see that list of other platforms ios android web. I will choose ios and here you can see the couple parts we can use to purports to install libraries is easily written go to it well and the second it s the faster basically in this first step. Okay.

Now i ll create a single web..

The name of the project is on the right the facebook login devil is the project aim as you stepped on the language and storyboard the my graphics file page next stop my piece is liking the tippet so sorry for that now my fresh fresh project is created where i to work all the facebook login part inside this project. Now i will open the terminal. Now i ll add libraries in the project. So that we can use the facebook services.

If we can sticky services in my project. Now. I m going to go to the path of my project. You can see it s a part of a project starting here right now now i m going to put in it to create the pulp file come on now this will generate the mod file where i can add the facebook sdk and every name so that i can download it from inside the project so here you can see that it s my port file.

I have created in this project now i m going to wear the hotlines or facebook. First ticket. He reaiiy copy pasted these three services. I am going to use in the project.

Now i will part install command to install those libraries in the project. Install now this will download and associate the libraries in the project in the meantime. I am going to do another work when these libraries will download you can see that installing facebook sdk korkut five point two point three one okay now in midterm. I will do another work let s get into it okay.

Here you can see that the face developer portal. Now and kate next. So. It s the second step in in setting up.

My facebook app. On the facebook. Platform. At apple developer environment.

Now. Second. Step is add your bundle. Identifier.

Here. I am. Going to add up project bundle identifier here. You can see my project bundle identifier way.

I can copy it from here based on the facebook posted a safe continue in the third step here i can see single sign on on your app..

We can use single sign on but in this project i am not going to use single sign on click next to set up other settings now here you can see the input list configuration for your project. Copy this settings in your project. Copy is complete. Okay.

I will skip the last two lines displayname and i copy both in here copy. It and i will paste in my project. Plist file here s my project. I ll go through oh realist and sources.

We were the source and now here i can face those lines. These are the settings basically my facebook id is added in the project now here i can use the application curie schemes. This is important because facebook will not allow until we add these lines we need to add these lines also the to be list. So i will copy it and paste and then for plist below here least now i can view as a list property list.

But here you can see that you order types at it you can see url types url schemes. Here you can see my pink caddy now here you can see the curie schemes. These are the curie skills for holding for 30k shoes and other services. No these are the settings have added in my project now here are the degrees are installing now here is a good setting you can set in the other linker flags in the project settings.

We ll add obj flag in the project. So it will not problem later this is with this obs obc will be added project is my project and now i m going to add objc link curve like the file search failure is the other liquor flag step. I will click it twice o pg c. Copy.

It exactly what is written here. And based. It these are the requirement. A sickly to use is against decay in your project.

Click next is the objective c thing we need to skip this as we are developing in the swift version. These are for objective c to skip. This part. I am going to add a facebook.

Okay now now in my project storyboard. I will add a button of the screen. And you my system is a little bit slow sorry for that now here is my storyboard opened. And i will add a button on my storyboard and center has article even vertical indexing the files taking a little bit time.

I add a button drag this button of my storyboard..

You can see that system is fitted with soap. Okay. I will type in the center of the screen and add a card state center horizontally or vertically and vertically is there tab is a bottom a selected key for the tabs for constraints. I will add a constraint from here.

It is not compulsory here is a tab. I have identically in the container and vertically in the container center but politically and vertically now name my button login with facebook and other clean the background clip and program text the background color. I said over text i will a test so it will look good twice you okay. Well adam whitman straight to the board and go to assistant.

You it can hold becoming tired of my button created a bi outlet of that bucket of ib action sorry and name of the action is login net. We tapped whenever this button clicks. This method will be called here they re gonna be tapped their code logic start in this button. Now here you can see that all the libraries are installed in my project installed every 4 sdk locking kit for facebook and facebook log in s ticket.

Here the four libraries are tied in the project. No oh open the project directory. I ll add this work open the project using this workspace file. Because i added.

But i take like waves using port now i need to open this workspace. 12. Now open it and now here you can see bots project. It here is my pod file see these three port lines.

These are the libraries. I did it in project and now go to delegate. This is my delegate file. Whenever project starts this file calls and this is my viewcontroller file.

Where i edit the action of my button. This is my storyboard to load input intake little boot time now my code logic start from here. Where the button apps will create a function. If we login all logic goes inside this mp login will call this my login button pressed.

I love it see the time now in this method. I ll go to okay now listed better to save the time. This is my ip model method i use basically facebook as kiki logging manager to authenticate in this method. I ll give the formations.

I used basically public profile tort email friends for missions..

That is my noggin. Read permissions. It will give me facebook. People will give me the name and name credited attached to my app.

So that is my adjective read permissions put up airs here and check it out okay. Now you can see i use three cases for login result. Number. One is the oil case when user where to authenticate with facebook and very is canceled and their third morning success open their like this also cancel user phantom mountain process process here easy dmv can easily understand ok commented ford lines because about queuing.

It this is the get a user pitter patter to its get to use a data so this method basically h. For my first name last name it an email from the facebook using graph api here i m writing that which is well so to get the facebook user details. Okay now i change the team here in the beta. That is why you can see the dart team okay.

These are my cases so cases. I already said you that because we re cases cancel case of this case. We re successful success. I will flash to facebook.

Profile. Here is my method for theta is cuckoo fun that is basically graphic a method please put graphically to find the facebook user profile here you can see that facebook graph epa sticky matter like okay i copy pasted because you save the time here is the parameter and pass in me and a graph. But p my profile and female gender and picture. I need to fetch from the facebook and we add a breakpoint and one the app.

Now you can see that all this rapidly refresh the page. I love tap on this input to authenticate me and open up facebook joy are the credentials of our test account type of facebook password login. Now you can see that we will obtain the number for you to the facebook to authenticate it and now here is my breakpoint is the graphic. A success case where you can see that pervasive error will not return then it will return my name of my user that is emphatically.

I ll assign it to the label and similarly. I ll press the email and assign it to the label place that way you can see that these are the two levels. I added on the storyboard. I will show you here my storyboard if you can see there labels which are used for one number from per user name an editor or email mint so that you cannot confuse you first i first in richard for this tutorial and we subscribe over fire tv to that will motivate me and keep ” .


Thank you for watching all the articles on the topic Facebook Login using swift Facebook Integration. All shares of star-trek-voyager.net are very good. We hope you are satisfied with the article. For any questions, please leave a comment below. Hopefully you guys support our website even more.


Leave a Comment