w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML Categories
Not able to login in facebook with facebook sdk 3.0 loginbutton button using other users, though it is working with developers login credentials
In your facebook's dev account check that your app is set to sandbox mode, so only developer accounts could get access token from app's ID, once you disable sandbox mode, your app will go live and you can log in with any facebook id.

Categories : Android

php Get users instagram photos and videos using Oauth without user authentication?
You can get it using the User's ID with the user media recent endpoint. This endpoint will return media for the user with ID 1234: https://api.instagram.com/v1/users/1234/media/recent

Categories : PHP

How to Authenticate Users With Facebook Connect?
Actually the question wasnt very clear.. I am taking a shot in the dark. Here is how the facebook login flow.. connected. The person is logged into Facebook, and has logged into your app. (*I think this is your case when you goto to your app from facebook tab. Whenever a user take any app through facebook they are automatically connected else if a user is logged into fb and a user take your app from another browser tab. You wont be connected but will be in a state of not_authorised described below. if a user is not authorised he will need to login again for your app*) not_authorized. The person is logged into Facebook, but has not logged into your app. (I think this is your case when you goto your app through the url you specify in browser and not through facebook tab) unknown. Th

Categories : Asp Net

Authenticate users using Facebook API through open-graph extension in yii
I have added the following rules in the controller. That helps in authenticating Facebook users. Code array('allow', // allow authenticated user to perform 'create' and 'update' actions 'actions'=>array('buy'), 'expression'=>'Yii::app()->facebook->getUser()', ),

Categories : PHP

Android : Authenticate user via facebook login in custom app
You should put the intent to start the next activity in your session status callback (inside the if(Session.isOpened()) check, where you're currently executing a "me" request. The SDK is necessary to run your app, but not the Facebook app. The SDK is included (and bundled) with your apk, the Facebook app is a separate apk, and is not required for log in with Facebook. If you get that error, that means you don't have the right key hashes in your settings. Did you sign using a different keystore?

Categories : Android

Why is facebook api asking this message on login with facebook for authorised users - "Application name" would like to access your friend list.?
The Facebook app authorization screen says that the app would like to access your friend’s list. But in truth, the app probably didn’t ask for that. The friends list is part of every app authorization, whether the app wants it or not. This is because Facebook wants apps to add social context, which can only be done with the friends list. But this doesn’t give the app the ability to contact your friends on your behalf, at least not more than it could do so without you adding the app anyway. Check for an reference https://www.facebook.com/about/privacy/your-info-on-other#applications

Categories : Facebook

Facebook login on iPhone. Authenticate with Rails Backend (Devise+Omniauth)
I'm not familiar with the iPhone piece, but your approach after that is generally accurate. The only exception is that you would typically use provider + uid to find or create a user, rather than a token. That might be what you meant by your #5, but it wasn't clear to me. Beyond that, there is a good (paid) Railscast on the subject of Omniauth + Devise, which would probably be worth the price for you: http://railscasts.com/episodes/235-devise-and-omniauth-revised It covers how you can receive and handle the auth hash, and it gives you a nice starting point for what your methods will look like.

Categories : IOS

Can we authenticate facebook user which view page in UIWebView?
I also faced the same problem for liking pages i found this https://github.com/brow/FacebookLikeView it is very help full go through this it shows how to like face book pages by using web view hope this helps

Categories : Objective C

Facebook authentication without login button
Something like this private void performFacebookLogin() { Log.d("FACEBOOK", "performFacebookLogin"); final Session.NewPermissionsRequest newPermissionsRequest = new Session.NewPermissionsRequest(this, Arrays.asList("email")); Session openActiveSession = Session.openActiveSession(this, true, new Session.StatusCallback() { @Override public void call(Session session, SessionState state, Exception exception) { Log.d("FACEBOOK", "call"); if (session.isOpened() && !isFetching) { Log.d("FACEBOOK", "if (session.isOpened() && !isFetching)"); isFetching = true; session.requestNewReadPermissions(newPermissionsRequest); Request getMe = Request.new

Categories : Android

Authentication using Tomcat realm or Facebook login
One option could be to use a Combined Realm: See http://tomcat.apache.org/tomcat-7.0-doc/realm-howto.html#CombinedRealm Realm 1 should be JDBCRealm, then implement realm 2 (FacebookRealm). You might change the order, based on which one is the most frequently used. See Tomcat docs for how to implement a realm. Of course you don't have a password in FacebookRealm, but you could do the following trick: JDBCRealm: username = username/userId in your application password = password FacebookRealm: username = username/userId in your application password = unique user id provided by Facebook This could allow users to log in with whatever method they want. Basically, this could be a possible use case for logging in through FacebookRealm (first steps might be a little bit different with JS SDK, b

Categories : Facebook

How to deal with 2-step authentication for Facebook on Spotify login?
I think if you try to login 3 or 4 times, then facebook very helpfully gives you an "account alert" on their website and lets you verify that you were actually trying to login and then it should work. I'm not sure about the better way to do this. Two factor auth still trips up even many of google's login mechanisms that don't even involve oauth.

Categories : IOS

callback issue in Facebook while user clicks anywhere while Facebook login page is loading
Goto onCreate() method of WebDialog.java in FacebookSDK library, you will find following statement: spinner = new ProgressDialog(getContext()); add the below statement after it spinner.setCanceledOnTouchOutside(false); you are ready to go!

Categories : Android

iOS native Facebook Login fails for Mobile Safari authentication
I happened to fix the issue. The bug was, I was requesting read and write permissions in the same call. Taking out the "publish_actions" from permissions solved the issue. I tested Facebook Login in iOS6+ through native FB login, native FB app, and webapp. Also tested on iOS5.1.1 through native FB app, and webapp.

Categories : Facebook

iOS Facebook login, handle different access tokens and determine users identity
The only way to unite the two memberships is to use a common link as a username or identifier such as email. I am sure fb, google, yahoo and others relay the users email account information. Your database should allow for storing your user's email address. The hurdle then becomes what do you do when user login with facebook then the next day using gmail that's when it gets tricky and you have to implement some mechanism for those accounts to be linked.

Categories : PHP

How can I authenticate users on Ignite Openfire against my MongoDB instance that contains users?
I am pretty sure you will have to create your own AuthProvider since the built in DB provider is JDBC based (which I assume doesn't work with MongoDB, but that is an assumption). I haven't done it, but I would guess it isn't that hard to do. The interface is fairly simple.

Categories : Mongodb

authentication, cant go through login page
one of the conventions in rails is, that public methods in a controller are considered to be actions. if you want to write methods for before_filter etc, make them private or protected so that rails will not expose them as actions. on the flipside, you are not able to define actions as private.

Categories : Ruby On Rails

Using created Login Page for authentication in ASP.NET MVC 4
In ASP.NET MVC, your URLs don't map to files; they map to actions. So, having a file at ~/Accounts/PasswordLock.aspx doesn't help. What you need is a route for that URL. The routes are usually set up in a file called RouteConfig, under the App_Start folder, executed by the Application_Start() method in Global.asax. The usual default route looks like this: routes.MapRoute( name: "default", routeTemplate: "{controller}/{action}/{id}", defaults: new { id = RouteParameter.Optional }); This means that a URL that goes www.example.com/Accounts/PasswordLock will map to a controller called AccountsController, and a method on that controller called PasswordLock. This method should return a View which by default will be called PasswordLock.cshtml. Note that the new Razor v2 view engine

Categories : Asp Net Mvc

Drupal 6 - Redirect Anonymous Users to Login Page
Hope the following links could help u.. :) https://drupal.org/node/300607 http://drupal.stackexchange.com/questions/51523/content-access-module-hiding-menu-links

Categories : Drupal

Why can't the login page for form-based authentication be written in JSF?
It's because <h:form> submits to the current URL (in web development terms also known as "postback"), not to j_security_check, while the form based authentication intercepts on j_security_check URLs. It's however not true that using a JSF form for form based authentication is impossible. It's quite possible, you only need to perform the login in backing bean using HttpServletRequest#login() yourself. See also: Best way for user authentication on JavaEE 6 using JSF 2.0?

Categories : Security

How to track the users have became fans of my facebook page?
This can be done with FQL (Facebook Query Language) using the Facebook Graph API. What you're looking for is the likes attribute which can be obtained from the JSON returned by http://graph.facebook.com/yourusername. Ofcourse you will need to do further queries to obtain things like how many friends of a specific user liked your page. Probably something along the lines of SELECT ... FROM like WHERE object_id = yourpage and I would imagine you'd need to link that to the friend table with something like WHERE uid1 = friendid to get their friends.

Categories : Facebook

Facebook different users posting to different pages as the page itself
For posting to a page as the page, get a page access token: https://developers.facebook.com/docs/facebook-login/access-tokens/ To post as the page, you need an access token with manage_pages permission. And there’s no build-in way for a page admin to get notified when someone wants to post to their page as the page, because that’s not a common use case. But the page admin can grant you manage_pages once so you get a page access token, and then you can use that in your app to post to the page, you just have to set that access token explicitly when doing so.

Categories : Facebook

How to post to users' facebook wall even if they are not on my app web page
You can request a long lived token for 2 months https://graph.facebook.com/oauth/access_token? client_id=APP_ID& client_secret=APP_SECRET& grant_type=fb_exchange_token& fb_exchange_token=EXISTING_ACCESS_TOKEN see https://developers.facebook.com/roadmap/offline-access-removal/

Categories : PHP

redirect omniauth-facebook to a specific page after authentication
When your get user by find_for_facebook_oauth method then you can login with that user and use redirect_to for your desired path. You can do something like: class Users::OmniauthCallbacksController < Devise::OmniauthCallbacksController def facebook # You need to implement the method below in your model (e.g. app/models/user.rb) @user = User.find_for_facebook_oauth(request.env["omniauth.auth"], current_user) if @user.persisted? sign_in(@user) redirect_to desired_path, notice: 'Signed in successfully.' set_flash_message(:notice, :success, :kind => "sign in successfuly") if is_navigational_format? else session["devise.facebook_data"] = request.env["omniauth.auth"] redirect_to new_user_registration_url end end end

Categories : Ruby On Rails

Facebook login page is mirrored when in RTL
Got it :) Before the line in the question I added this: App.RootFrame.FlowDirection = System.Windows.FlowDirection.LeftToRight; To return the app into LTR so the Facebook page will be formatted correctly and not mirrored. In order to return it after the login had finished I added this line when I finished with the login: App.RootFrame.FlowDirection = System.Windows.FlowDirection.RightToLeft; It happend because the facebook login page is shown inside a Browser control so the actual text doesn't get mirrored correctly. I guess the Facebook C# SDK people should have thought of it.. so I think we can say it sort of a bug. Hope I helped you, future viewers!

Categories : C#

PassportJs. How can I get facebook redirect uri without redirecting user after call passport.authenticate('facebook')
Passport is poorly documented on this issue - I struggled with it for a long time as well. I found you can call passport.authenticate(type, fn)(req, res, next), and within fn, you can distinguish between a user who can login and a user who can't. It's up to you to call req.logIn though. Just FYI, I'm assuming you're using sessions: module.exports.createSession = function(req, res, next) { passport.authenticate('local', function(err, user, info) { if (err) { res.json(500, {ok: false}); } else if(!user) { // you would probably want to do more work here // for example distinguishing between bad login credentials, // canceling, users not ready to log in (pending), etc. res.json(401, {ok: false}); } else { req.logIn(user, function(err) {

Categories : Angularjs

Using Parse for Facebook login but i get --https://api.parse.com/1/users 404-- After Refreshing 3 Times
"User cancelled the facebook login or did not fully authorize" means that you are already logged in. Use chrome's developer tools console to check if your current user using this commmand: Parse.User.current() If you get an object, you are already logged in. You can use Parse.User.logOut() to logout, then Parse.User.current() should return a null! Also you can use Parse.User.current().get('authData')['facebook'], as mentioned here Notes: If logging out from parse logs you out of facebook, update your parse reference

Categories : Javascript

How can I work locally with facebook login with the settings of App Domains and Website with Facebook Login?
Let's say you are doing local development and your app hosted locally with url: http://localhost:53750/ Go to your settings on Facebook: Apps-> YOUR_APP_NAME -> Settings -> Add Platform Select WebSite and enter your url and save changes After that you should have something like: Done. Try to login from your web app.

Categories : Misc

how to redirect loggedin in users from viewing login page in django, using generic views
I would override dispatch method: class LoginView(generic.edit.FormView): def dispatch(self, request, *args, **kwargs): if request.user.is_authenticated(): return HttpRedirect('/whatever/') else: return super(LoginView, self).dispatch(request, *args, **kwargs)

Categories : Python

Loading the login page outside of IFRAMES when the authentication ticket/cookie expires/times out
There's no way to have a Redirect instruct the browser to redirect to a new page. The redirect will always happen within the iframe. You could change the "timeout" page: <configuration> <system.web> <authentication mode="Forms"> <forms loginUrl="~/Account/Timeout" timeout="1" /> </authentication> </system.web> </configuration> And then in the timeout page you will need to have a link like this: <a href="" onclick="window.top.location.href='/Account/LogOn'">Login Again</a> References: Redirect the parent page from IFrame How to redirect to logon page when session State time out is completed in asp.net mvc Note: You could avaoid this by not using IFRAMES. They are generally frowned upon an

Categories : C#

Post on Facebook Page's wall without having to login (C#)
Yes, it's possible. You need to use a page access token. Generating a Page Access Token. Once you receive a page access token, you can store it as it never expires(if generated through long-lived user token/server side user token). Finally initialize your FacebookClient with that token. A C# specific tutorial is here. The article really old and using the deprecated offline_access permission, but atleast you will get the logic right.

Categories : Asp Net

Facebook javascript sdk login page using ajax and php
Put the appId in this line FB.init({appId: 'your app id', status: true, cookie: true, xfbml: true}); As below and check: FB.init({appId: '178812232292862', status: true, cookie: true, xfbml: true}); *Updated Code: <script> $(function() { window.fbAsyncInit = function() { FB.init({appId: '178812232292862', status: true, cookie: true, xfbml: true}); FB.Event.subscribe('auth.login', function(response) { if (response.authResponse) { FB.api('/me', function(response) { console.log(response); // User Details }); } //window.location.reload(); }); }; $('body').append('<div id="fb-root"></div>'); $.getScript(document.location.protocol + '//con

Categories : Jquery

Get facebook login popup every time user try to Login using facebook from my website
If you want to login the user everytime he visits the app, you should implement FB.logout, when you get the status as connected on getLoginStatus() when the app starts. So the session when be destroyed and then you can call FB.login again. Just like- // app starts here FB.getLoginStatus() { if(status == "connected") // call FB.logout() // call FB.login() else // call FB.login() }

Categories : Javascript

Facebook login on page - what when user delete app in own account?
I'm presuming by "still have my app on his account" you mean your app is still authorized to access that user's account with whatever permissions you've requested/the user granted when signing onto your site. If you've followed Facebook's instructions on implementing Facebook Login for Web on your site (https://developers.facebook.com/docs/facebook-login/getting-started-web/) you are probably already set to handle user revoking FB permissions from your app (or deleting your app from those allowed access to his/her account). Basically, when a user accesses your site and uses Facebook login you send a request to FB API to check their current login status: https://developers.facebook.com/docs/facebook-login/login-flow-for-web/#checklogin and if the returned result indicates that they are,

Categories : Facebook

facebook login on iphone leaves blank page
Okay, I found a solution for doing this in my iOS app for an integrated UIWebView. When someone is not logged in to facebook a popup opens and requests a login. After logging in the user is redirected back to the page from where he hit the like button. However in the UIWebView this redirect URL leaves the user with a blank page. The solution to the problem is to intercept the redirect URL and reload the page with the like button. So, with UIWebView one can intercept the requests before the actual webpage is loaded and react on certain URLs. The code for this look like this: - (void)viewDidLoad { [super viewDidLoad]; self.webview.delegate = self; [self.webview loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:@"http://www.example.com/facebook_like_box.html"]]]; }

Categories : Facebook

Is it possible to call native ios Facebook login dialog from just a web page (not a web app)?
No, it is not yet possible to directly authenticate the user via the native Facebook App, but it's possible to authenticate the user using a custom URL scheme which opens your native iOS app which then handles the authentication flow: The user authenticates natively with your iOS App. You then store the user login (not password) in your app (i.e. using NSUserDefaults). Then the user opens your web page in Mobile Safari. You redirect the user via a custom url scheme to your app (i.e. using myapp://authenticate). Apple documentation on implementing custom URL schemes: click Now, if you have an active FB session in your iOS app, you can either directly redirect the user back to your landing page in Mobile Safari, passing the access token via url get parameter or you first re-authenticate th

Categories : IOS

How to fetch particular users photos from Instagram
I am not sure what you're using, but the Instagram API absolutely provides an end-point for an individual user's photos. Once you've obtained the user's ID you can use the /users/user-id/media/recent and /users/self/feed endpoints as required. What API calls are you currently using, if not those?

Categories : Iphone

Mobile Website Facebook Login using Facebook App for login details
I think its not possible, because we wont link browser and an app. I developed one android app with facebook login integration.If facebook native app already logged in, now i click my app facebook login button it directly redirect my app to my home page without asking fb username and password. For me i used local storage in javascript localStorage.setItem("userName", userName); localStorage.setItem("password", password); var uname=localStorage.getItem('userName'); var pass=localStorage.getItem('password');

Categories : Facebook

Looping through users with Instagram API requests is REALLY slow
Doing the requests sequentially will take longer than doing the requests in parallel. You'll want to do concurrent requests to speed this up. Take a look at this answer using curl_multi.

Categories : PHP

Using PHP to authenticate users in an ASP.NET membership
I took a look at the authentication question page that you linked to and one particular answer captured my attention: http://stackoverflow.com/a/4227642/633098. Because you said that the algorithm used no longer was SHA1 but more probably SHA256 I started experimenting with HMAC hash, SHA256 instad. It didn't work at first but then I tried using both the concatenated string consisting of the password and the salt in conjunction with the salt (= key) itself, and it worked. Here's the simple function I made: function _hash($password, $salt) { return base64_encode(hash_hmac('sha256', base64_decode($salt) . iconv('UTF-8', 'UTF-16LE', $password), base64_decode($salt), true)); } $salt = 'Mu1tp8XzfKl8dSTVAZm44A=='; // Straight from the DB $password = 'testing'; var_dump(_hash($password,

Categories : C#

How to login to Instagram from codebehind?
first of create Developer app in Instagram and get consumerkey & consumersecret and set path call back url somthing link http://localhost:3104/Instagram.aspx private void Authentication() { string rest = string.Empty; GlobusInstagramLib.Authentication.ConfigurationIns config = new GlobusInstagramLib.Authentication.ConfigurationIns("https://instagram.com/oauth/authorize/", ConfigurationManager.AppSettings["consumerKey"], ConfigurationManager.AppSettings["consumerSecret"], ConfigurationManager.AppSettings["callbackurl"], "https://api.instagram.com/oauth/access_token", "https://api.instagram.com/v1/", ""); oAuthInstagram _api = oAuthInstagram.GetInstance(config); rest = _api.AuthGetUrl("likes+comments+basic+relationships"); Response.Redirect(re

Categories : C#



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.