I want to know if a visitor to my website is logged into facebook or not? And what information will I be able to fetch from the user's fb profile, so that to login user on my website if user had already synced his fb account?
Is it possible to know if my visitor is logged into facebook?
775 views Asked by Dreamer At
2
There are 2 answers
1
joepio
On
Facebook's API has a function FB.getLoginStatus() that returns either a connected, not_authorized or unknown string depending on if the visitor has authorized your application, has logged in to facebook or neither.
If you want user data, like a picture or a name, you're gonna need to authenticate your application.
Related Questions in JAVASCRIPT
- Using Puppeteer to scrape a public API only when the data changes
- inline SVG text (js)
- An array of images and a for loop display the buttons. How to assign each button to open its own block by name?
- Storing the preferred font-size in localStorage
- Simple movie API request not showing up in the console log
- Authenticate Flask rest API
- Deploying sveltekit app with gunjs on vercel throws cannot find module './lib/text-encoding'
- How to request administrator rights?
- mp4 embedded videos within github pages website not loading
- Scrimba tutorial was working, suddenly stopped even trying the default
- In Datatables, start value resets to 0, when column sorting
- How do I link two models in mongoose?
- parameter values only being sent to certain columns in google sheet?
- Run main several times of wasm in browser
- Variable inside a Variable, not updating
Related Questions in FACEBOOK
- Facebook Post Images from local system on own Page
- Provide an archipelago name that humans cannot utter
- How can I look this email address
- Not getting all leads from Meta/Facebook using webhook for page leadgens
- Unsupported post request when trying to create a custom audience via the endpoint https://graph.facebook.com/lapi-version), (custom-audience-id/users)
- Java resized JPEG seems to be invalid format for Facebook?
- How to implement facebook pixel in flutter in 2024 any example?
- Need WhatsApp Data Backup from Api
- Facebook login via JS-SDK via OAuth will get stuck half-way
- Short time token with the Graph API and Facebook login through the iOS SDK
- Facing the "Messaging may be unavailable" error - WhatsApp Cloud API
- Facebook Graph API - Story endpoint does not return all active stories
- Javascript / Dynamically append text element above embedded facebook posts
- When I post text with media on Facebook, the text does not show
- How to search a list of groups using facebook APIs
Related Questions in API
- Google Sheets API - Append Request not working
- Is there really no product for docs that has these?
- How to show suggested content in response using Azure Cognitive Search?
- error message when closing current position in binance futures, using ccxt library
- How to filter API data in React Native
- I have fetched an API with JS, but the output looks really bad and I don't know how to fix it
- Session is not storing in react and Asp Dot Core Web API
- Apex charts not rendering series value, showing cannot map values of NULL
- Configure IIS to accept API calls only from API Manager, Deny from direct calls
- Problems with API return using the Axios library in NextJS
- How to query by Iteration in pyral?
- Is there a way to have a user enter a url query and have a single function filter a database?
- Cant get value in Vue from data
- Read stories/posts using instagram API
- Need To Make Minor Change To REST API Response
Related Questions in STATUS
- Activity status in Node js
- Ticketstatus on DynamicsCRM updates on TFS Ticketstatus change
- Simple Python Server - How to prevent sending 304 on either end?
- Drawer component can't close or open if a redux status is passed through the component props, but works directly if called in handler funtion
- blank orders being generated in WooCommerce with no details and a pending payment status,
- Payment gateway status check for vending machine
- Rails + Stripe: Enum status stays nil after update and save
- Woocommerce custom order status with customized email notification
- Add a Cancel order button to WooCommerce My account View Order pages
- Send text in email depends on status of checkbox in WCF7
- Podman Container Created Status
- Obtaining varied results using the grep command
- WooCommerce Virtual products - Autocomplete orders after payment
- Target status of deployment group in azure devops shows offline most of the time even though server is running
- What causes exist status 2 error? (GOLang)
Related Questions in LOGINSTATUS
- Hide tags in wordpress posts (blogs) via CSS for logged-out users
- ASP C# - logoutaction redirect not working
- firefox Disable right click Fill password
- Facebook login button - how to check if we're logged in before attempting to login?
- Logout button intercept enter key
- Login control inside updatepanel
- Is it possible to know if my visitor is logged into facebook?
- SQL server 2008 r2 Last database user date and time
- Alternative to ASP.NET LoginStatus Control in C#
- asp.net login status changing throughout
- TypeError: theForm.submit is not a function with asp:LoginStatus
- LoginName does not display and Loginstatus automatically change to Login after user login (Asp.net)
- LoginStatus redirect works only in explorer
- How to get all username status in a VB.Net application
- LoginStatus does not redirect
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
You can only create an App and check if the User is authorized - without authorization, he is completely anonymous. What information you can fetch is explained in the API reference: https://developers.facebook.com/docs/graph-api
For example, you can check if the user is logged in with
FB.getLoginStatus: https://developers.facebook.com/docs/reference/javascript/FB.getLoginStatusMore information: