0

When I use Facebook Login (JavaScript) on my website, I receive the user id from Facebook in the browser.

Secondly I want to fetch some data from the database using said user id.

SELECT * FROM some_table WHERE user_id = 123400000001;

How can I pass the id to PHP without the user being able to alter the id?

the.salman.a
  • 864
  • 8
  • 25
allanth
  • 354
  • 4
  • 18

1 Answers1

0

Apart from user ID, you also receive an access token, which you can pass to your backend and use for the verification of the user (using this method, for instance).

Jiri Kapoun
  • 163
  • 8