使用javascript为google + link设置文本(set text for google+ link with javascript)

编程入门 行业动态 更新时间:2024-10-28 08:27:37
使用javascript为google + link设置文本(set text for google+ link with javascript)

我想用一些数据打开谷歌共享对话框,我现在使用它:

var GOOGLE_BASE_URL = "https://plus.google.com/share?url="; url += GOOGLE_BASE_URL + urlToShare; window.open(url, null, DIMENSIONS);

如何设置插入评论部分的文本?

I want to open a google share dialog with some data, I use this as of now:

var GOOGLE_BASE_URL = "https://plus.google.com/share?url="; url += GOOGLE_BASE_URL + urlToShare; window.open(url, null, DIMENSIONS);

How can I set the text that will be the inserted into the comment section?

最满意答案

预填充共享文本的唯一方法是使用交互式帖子代替共享链接。 这是Google+登录附带的功能。 如果您尝试使用普通共享方法,它可能不是最佳解决方案。 但是,如果您已经使用Google作为身份验证方法,那么Google+登录可能是您的不错选择。 交互式帖子不仅允许您预填充文本,还可以预先填充最多10个共享收件人,这些收件人将直接通知共享。

The only way to prefill the text of a share is to use Interactive Posts in place of the share link. This a feature that comes with Google+ Sign-In. It may not be the best solution for you if you are trying for a general share approach. However, if you are using Google as an authentication method already, then Google+ Sign-In could be a good option for you. Interactive Posts not only allow you to prefill text, but also to prefill up to 10 recipients of the share, who will all be directly notified of the share.

更多推荐

本文发布于:2023-08-07 15:01:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1464678.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:文本   google   javascript   link   text

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!