创建带有链接的 Facebook 对话框弹出窗口
我正在尝试使用上周发布的新改进来创建 Facebook 对话框。
http://developers.facebook.com/blog/post/437
我想要的是能够有一个链接,这样当点击它时就会生成一个弹出窗口,或者让它显示在页面中。我尝试将它放在 DIV 中,然后用 JQuery 显示,但它不会在页面上居中。我已经获得了用于发布到用户墙的代码...只是不知道如何格式化 JS 代码和/或创建弹出窗口的链接。 提前致谢!
I am trying to create a Facebook Dialog using the new improvements that were released last week.
http://developers.facebook.com/blog/post/437
What I want is to be able to have a link so when it's clicked a popup is generated, or have it show up in the page. I've tried putting it in a DIV and then showing with JQuery but it won't center on the page. I've gotten the code to work for posting to the users wall... just don't know how to either format the JS code and or create the link for the popup.
Thanks in advance!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
只要您的页面上有 Facebook js,创建好友邀请就这么简单:
您可以使用 Facebook 上的 javascript 控制台应用程序来测试这一点:
http://developers.facebook.com/tools/console
粘贴上面的脚本,包括标签,或单击底部的“示例”按钮文本区域并找到“fb.ui —friends.add”示例。
As long as you have the Facebook js on your page, it's as easy as this to create a friend invitation:
You can test this by using the javascript console app on Facebook:
http://developers.facebook.com/tools/console
Paste in the script above, including the tags, or click the "Examples" button on the bottom of the text area and find the "fb.ui — friends.add" example.