在 Facebook Wall 上共享我的 Web 应用程序的数据
用例 - 我有我的 Web 应用程序,当用户单击链接时,我想将应用程序中的一些数据手动发布到我的 Facebook 墙上。
我目前使用的共享链接如下 -
https://www.facebook.com/sharer/sharer.php?u=&t=titleABC" target="_blank"> 在 Facebook 上分享
问题 - 我看到打开一个新窗口来发布数据。我的数据也发布到我的墙上,但我希望标题使用我的应用程序中的数据填充,而不是要求用户“写一些东西”。我希望文本框填充标题中的消息(t 来自 url 参数)而不是用户可编辑的。 有没有办法做到这一点。
Usecase - I have my web application and I want to post some data from my application onto my Facebook wall manually when a user clicks on a Link.
I'm currently using Share Link as follows -
https://www.facebook.com/sharer/sharer.php?u=&t=titleABC" target="_blank">
Share on Facebook
Issue -
I see that a new window opens to post the data. My data also gets posted to my wall, but I want the title to be populated with data from my application rather than asking the user to "Write Something".I want the text box to get populated with the message from the title(t from the url parameter) rather than user editable.
Is there a way to do this.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
使用“共享”按钮共享您的内容非常简单。就我而言,我对 html 中带有 id sharebuttonfacebook 的按钮这样做了,
除此之外,您还需要注册一个应用程序。
没有什么比这更简单的了。
只需访问 http://www.facebook.com/developers/app
并注册您的新应用程序。
他们会给你一个简单的代码,必须放在正文之后,就像这样 -
有了这两件事,你就可以决定在 Facebook 上分享什么。
此外,在我们上面创建的函数中,您可以替换您喜欢的任何变量,从而使其动态。希望这能回答您的问题。
PS:如果它可以变得比这更好,你不需要用户的任何许可!
Sharing your content with Share button is absolutely simple. In my case I did it like this for a button i have in my html with id sharebuttonfacebook
In addition to this you need to register an app.
Nothing could be simpler.
Just go to http://www.facebook.com/developers/app
and register your new app.
They will give you a simple code that has to be put just after the body which goes like -
With these two things in place you can Decide what to share on facebook.
Also in the function we have made above you can substitute whatever variables you like hence make it dynamic. Hope this answers your Question.
PS: If it could get better than this you dont need any permission from the user!