I want to use ajax to call php page, where php page creates a facebook event using facebook api.
I tried it, but it didn't work , did i make something wrong or it is not allowed to use ajax with facebook api ?
It should work as long as you get the correct access for the user. Are you getting an error?
Related
I'm making API call for other developers to use, so my question might sound silly but i need the community help. So thanking in advance.
I finished an API call for a web service using this https://github.com/chriskacerguis/codeigniter-restserver. All api calls working perfectly when i test it using postman plugin for chrome.
I've forwarded my API call to an android developer and he was able to use GET methods by using direct URL. now he is asking me to provide direct URL to the POST, PUT and DELETE API call, Which i do not know how to provide.
If for example, this is my API call to use the GET method, http://example.com/api/chemists/2 using the method chemists_GET. How do i get the direct URL to this PUT API call using this method chemists_PUT. like wise chemists_POST and chemists_DELETE method.
Kindly help me.
Yoyu have ki9nd of answered it yourself... with the link you gave...
You're URL's to the endpoints will be as you have them... however you will need to implement the post functions etc as defined in https://github.com/chriskacerguis/codeigniter-restserver#responses that page also described delete and put too...
I want to write a Facebook-tab application that can be modified to the page that will add it. So I am trying to find a way to access the parent page id from my Facebook tab.
Does anyone know a way to do that using Facebook PHP sdk v4?
Thanks!
Use FacebookPageTabHelper and the getPageID() method. First hit Googling gives me https://gist.github.com/niraj-shah/fcd17411def017e3aefc which looks like a good start for you
I am creating a Facebook application in the PHP SDK using the Graph API and I need to have a page to invite my friends to the application. Are there any methods in PHP to do the same?
I have seen the JavaScript method for this, but it doesn't match with my requirement (I need it as a page other than the JavaScript popup).
Read the documentation. If you do not use the JavaScript method, see the Direct URL Example paragraph.
For example, I have http://www.example.com/abc.html.
If I like this page, how can I detect me that have already like this page using facebook php api.
Give me help, please
You can collect who likes your page using the newest facebook sdk. What you would do is a sort of work around using their app interface, which is just a LIKE script for your site, and then call https://graph.facebook.com//subscriptions to record the information via mysql or whatever db you are using. I use this method when collecting facebook invites for random contests I hold.
You can use cookies that must be set in the Like button callback or can use Facebook Connect to check whether a user likes your page but this way requires extra permissions and a created facebook app.
Also there is a ready solution for jquery:
http://codecanyon.net/item/like-2-unlock-for-jquery/2822035
I need to grab the statuses from a Facebook page via PHP to display on the page. I don't want to have people logging in to facebook just for my script to grab the statuses from the page since it is a public page and isn't restricted. I have the Facebook API for PHP in my projects directory but have no idea how to use it to do what I want it to. Could someone give me a code example of how I'd do this? Thanks!
It's really a straight forward task if you follow the documentation. Since /PAGE_ID/feed requires any valid access_token, your app access_token is enough to get the data:
Open the Graph API Explorer (I'm querying coca-cola/feed)
Get an app access_token from the Access Token Tool and use it instead of yours
You're done!