Search code examples
jsonfacebookjsonp

How do i parse FB.UI string?


[[Object { uid="*****", name="Vini Katyal", is_app_user=true, more...}, Object { uid="*****", name="Vinay Katyal", is_app_user=true, more...}, Object { uid="****", name="Aviral Kumar", is_app_user=true, more...}, 3 more...]]

How do i parse this response tried JSON.parse(response) doesn't work for me.

Please help

Thanks


Solution

  • This is not a JSON string. A JSON string should look like this:

    {
        {"uid":"*****",
         "name":"Vini",
         "is_app_user":"true"},
        {"uid":"*****",
         "name":"Bla",
         "is_app_user":"true"}
    }
    

    Please check the documentation of the API you are accessing to see what kind of encoding is that.