且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Facebook请求2.0,如何更改“接受”按钮网址成为Facebook以外的网址?

更新时间:2023-11-27 13:50:46

不幸的是,接受按钮现在将永远带你到应用页面,你看到没有现在要走到其他地方。您必须从画布页面重定向它们。不过,我并不认为这是针对Facebook政策的,因为Facebook的请求最初可以从Facebook外部使用iframe插件发送。如果您想要将外部网址放入接受按钮,我将会记录功能请求与Facebook。


My app sits outside facebook canvas. The facebook request dialog 2.0 only redirects to canvas url eg. apps.ibibo.com/YOURAPP. How can I make it open a custom url ? This was possible in legacy FBML form with fb:request-form and setting req-url .

Are requests 2.0 restricted only to inside facebook URLS ? My requirement is to send game requests,but my game sits outside facebook. i.e. on clicking "ACCEPT" the url to open should be

"http://www.mydomain.com/mygame" and not

"http://apps.facebook.com/mygame" .

These methods do not seem to fit my requirement : http://developers.facebook.com/docs/reference/dialogs/requests/ ( only canvas url redirection )

I thought of one workaround as : The user clicks on "ACCEPT" and comes to the canvas url, and from the canvas url, I redirect him to my url outside facebook. But I am not sure if that is compliant with facebook policy ? ( mentioned here in point#4 of first paragraph : http://developers.facebook.com/blog/ )

Unfortunately the accept button right now will always take you to the application page as you are seeing and there is no way right now to have it go elsewhere. You would have to redirect them from the canvas page. However, I don't see this as being against the Facebook policy though as Facebook requests can be originally sent from outside of Facebook using the iframe plugin. If you wanted to be able to put in an outside url for the accept button, I would log a feature request with Facebook.