I have created a facebook application. Using php code to adding a tab in the Facebook page. And I want to change 'Secure Page Tab URL' for tab on the same App but I don't know how to do it!
Example:
tab A -> Secure Page Tab URL A / tab B -> Secure Page Tab URL B
Does any one have an idea about this? thanks!
You can only have one Secure Page Tab URL per App. If you want to show different content on different Pages, you have to parse the signed_request POST parameter to get the Page ID - and show different content depending on that ID.
More information: https://developers.facebook.com/docs/games/gamesonfacebook/login#parsingsr
Btw, it is not possible to add one App several times to one Page, just in case that´s what you want to achieve.
Related
I want to use dynamic URL for Facebook page tab for that purpose i want to need secure page tab URL different for every user how can i do this can any body help me?
Dynamic URLs per Page are impossible, it´s just one setting. You can get the Page ID though: https://developers.facebook.com/docs/php/howto/example_access_token_from_page_tab/ (see $helper->getSignedRequest())
Fields in signed_request: https://developers.facebook.com/docs/reference/login/signed-request
More information: how to read facebook signed_request to get user_id
I'm writing a PHP application that will serve as a Facebook Tab inside of a Page. In the application, the user has the option to Share a photo, be it on Facebook or as a link to put on other websites. The part with Facebook is easy, but my question is this.
How can I give someone a link to a page inside of a Facebook Tab?
For example, the direct url from which the tab loads the website is: http://my-site.com/tab
Inside of that website I have an url that looks like http://my-site.com/tab/photo.php?id=3
The url of the Facebook Tab is something like http://facebook.com/my-page/app_3932734623842
What I want is for the user to be able to paste a link on their twitter which would lead them directly to the page http://my-site.com/tab/photo.php?id=3 inside of the Facebook app.
Possible? How? :(
Thank you!
I've seem to have run into an issue here.
I have a voting/gallery app on a Tab of a specific page on Facebook.
So to provide a user with a direct link to a image in a Gallery(in the Paget Tab App), i generated a URL with APP_DATA, so I can pass data(image filename)to the iframe.
So basically my links look kinda like this:
https://www.facebook.com/pages/xxxxxx/xxxxxxxxx?sk=app_xxxxxxx&app_data=showimage.php%3Ffilename%3D1336314789stevakralj%2Ejpg
Now, when I try to create a Like button for this Link, I get nothing.
Any ideas?
I have exactly the same problem... In my app, which is hosted by a page tab, the "Like" buttons for each item apper correctly and the "data-href" attribute for each "like" button has the same format as yours, but EVERY like button points to the Facebook page which hosts the app, not to the individual item... so, for every item in my gallery, the "like" information under it is exactly the same (number of likes for the page hosting the app) and if I "dislike" any item, I "dislike" the entire page.
I have tried the same format but the parameter NOT on a facebook page... then it works... I don't see a difference but:
https://www.facebook.com/pages/xxxxxx/xxxxxxxxx?sk=app_xxxxxxx&app_data=abc (DOESN'T WORK, for each item which have app_data different)
https://www.mytestweb.com/test.aspx?sk=app_xxxxxxx&app_data=abc (WORKS for each item which have app_data different)
Facebook doesn't seem to allow linking directly to a tab page so strips your app ID from the URL. There's no way to get around this except by linking to an external site that bounces back to Facebook.
i've setup a application that has a path to:
www.some_page.com/index.php
on the page i have a link that goes to:
www.some_page.com/picture.php?number=123
this page displays in the same fb iframe application.
My question is how to get to www.some_page.com/picture.php?number=123 from an outside link?
if i just link to it it will take me to the page but outside the facebook app, and i need t to take me to that page inside the app..
i guess that when i click on that link i have to send the user first to accept the app access then got o that page ?!
any ideas?
Thanks
edit 1:
** what i want is to place a link to www.some_page.com/picture.php?number=123 on another site and redirect me that page inside the facebook app
There are 2 options to set a facebook app:
embed your www.some_page.com inside an iframe (this will make sure all your links will stay inside)
Follow this: http://developers.facebook.com/docs/appsonfacebook/tutorial/ and make sure you don't have target="_blank" this is a better option and your links should open in the same scope.
so i created a facebook app (fbml).
canvas url = http://mydomain.com/fb/canvas/
tab url = tab.html
i authenticated my app with my profile and added the tab to my profile. but the tab keeps loading and loading. sometimes i also get redirected to my profile page after a short tab loading time
trying to access my canvas page http://apps.facebook.com/myapp/ works fine. also trying to access my tab page (which must be realtive to canvas) works with the apps url http://apps.facebook.com/app/tab.html.
does anyone know why i cannot access my tab page via the tab of my profile? the content of tab.htmlis just a little bit of "lorem ipsum", no php, no js, no body tags, nothing, just text.
looking into web-inspector, there is a file called tab.php which gets queried via ajax, but the content of this file is
for (;;);{"error":1357010,"errorSummary":"Oops","errorDescription":"Something went wrong. We're working on getting it fixed as soon as we can.","errorIsWarning":false,"silentError":0,"payload":null}
is this a facebook issue? but the problem exists the whole day now
This is a bug. We're pushing a fix today.
Try specifying an absolute URL for your tab URL under your Facebook application's settings.