Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. JavaScript
  4. how to check if user is fan of a facebook page using javascript?

how to check if user is fan of a facebook page using javascript?

Scheduled Pinned Locked Moved JavaScript
javascripttutorialquestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Meax
    wrote on last edited by
    #1

    does anyone know how to check whether someone is a fan of a facebook page.

    Z V 2 Replies Last reply
    0
    • M Meax

      does anyone know how to check whether someone is a fan of a facebook page.

      Z Offline
      Z Offline
      zeGeek
      wrote on last edited by
      #2

      This link will help you : https://developers.facebook.com/docs/graph-api[^]

      1 Reply Last reply
      0
      • M Meax

        does anyone know how to check whether someone is a fan of a facebook page.

        V Offline
        V Offline
        Vfleitao
        wrote on last edited by
        #3

        you can do like this after having the user permission var user_id = 'USERID' var page_id = 'YOUR PAGE ID'; var fql_query = 'SELECT uid FROM page_fan WHERE page_id = ' + page_id + ' and uid='+ user_id; var query = FB.Data.query(fql_query); query.wait(function (rows) { if (rows.length == 1 && rows[0].uid == user_id) { //IS A FAN OF THE PAGE } else { //NOT A FAN OF THE PAGE } });

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups