如何登录推特在国内(苹果手机如何登录推特)

创建应用接入使用Hello.js访问使用Hello.js简化访问。facebook和twitter的访问方式是一样的。hello . js(http://ado

创建应用接入

如何登录推特在国内(苹果手机如何登录推特)

使用Hello.js访问

使用Hello.js简化访问。facebook和twitter的访问方式是一样的。

hello . js(http://adodson.com/hello.js/)是一个客户端JavaScript SDK,用于Web服务和请求它们的REST Api的OAuth2认证。

JS对路径进行了标准化,并对常见的API做出了响应,如谷歌数据服务、脸书图形和Windows Live Connect。它们是模块,所以这个列表还在增长。

//初始化并配置应用ID hello . init({脸书:脸书_客户端_ id,Windows: Windows _客户端_ id},{重定向_ uri:& # 39;redirect.html & # 39})//登录hello . on(& # 39;auth.login & # 39,function(auth){ //登录成功后,获取用户信息(fb和tw的用户数据有区别)。您好(auth.network)。API(& # 39;/我& # 39;).然后(function(RES){ console . log(RES)} })脸书登录后获取的用户信息

{电子邮件:& # 34;XX @ gmail.com & # 34,名字:& # 34;XX & # 34,id:& # 34;123456",姓氏:& # 34;XX & # 34,名称:& # 34;XX & # 34,图片:& # 34;网址& # 34;,缩略图:& # 34;网址& # 34;}登录}Twitter后获得的用户信息

{ "id & # 34: 123456, "id _ str & # 34: "123456", "姓名& # 34;: "XX & # 34, "screen _ name & # 34: "XX & # 34, "位置& # 34;: "", "描述& # 34;: "xx & # 34, "网址& # 34;: "网址& # 34;, "实体& # 34;: { "描述& # 34;: { "网址& # 34;: [] } }, "受保护& # 34;:假的,& # 34;关注者_计数& # 34;: 0, "朋友_计数& # 34;: 0, "listed _ count & # 34: 0, "创建于& # 34;: "Fri 2022年3月8日03时36分20+0000 & # 34;, "favourites _ count & # 34: 0, "utc _ offset & # 34:null,& # 34;时区& # 34;:null,& # 34;geo _ enabled & # 34:假的,& # 34;已验证& # 34;:假的,& # 34;statuses _ count & # 34: 0, "郎& # 34;: "恩& # 34;, "contributors _ enabled & # 34:假的,& # 34;is _ translator & # 34:假的,& # 34;is _ translation _ enabled & # 34:假的,& # 34;个人资料_背景_颜色& # 34;: "F5F8FA & # 34, "profile _ background _ image _ URL & # 34;:null,& # 34;profile _ background _ image _ URL _ https & # 34;:null,& # 34;个人资料_背景_平铺& # 34;:假的,& # 34;profile _ image _ url & # 34: "网址& # 34;, "profile _ image _ url _ https & # 34: "网址& # 34;, "profile _ link _ color & # 34: "1DA1F2 & # 34, "profile _ sidebar _ border _ color & # 34;: "C0DEED & # 34, "profile _ sidebar _ fill _ color & # 34;: "DDEEF6 & # 34, "profile _ text _ color & # 34: "333333", "profile _ use _ background _ image & # 34;:真的,& # 34;has _ extended _ profile & # 34:假的,& # 34;默认配置文件& # 34;:真的,& # 34;default _ profile _ image & # 34:真的,& # 34;以下& # 34;:假的,& # 34;follow _ request _ sent & # 34:假的,& # 34;通知& # 34;:假的,& # 34;translator _ type & # 34: "无& # 34;, "暂停& # 34;:假的,& # 34;needs _ phone _验证& # 34;:假的,& # 34;名字& # 34;: "XX & # 34, "姓氏& # 34;: "", "缩略图& # 34;: "网址& # 34;}脸书共享触发共享:

& lta href = & # 34JavaScript:void(0)& # 34;@ click = & # 34fbShare & # 34& gt脸书共享</a & gt;FB share(){ let share path = & # 39;'//别人分享后打开的链接let title = & # 39'//共享标题window . open(& # 39;https://www.facebook.com/sharer/sharer.php? u = & # 39;+ encodeURIComponent(共享路径)+& # 39;& t = & # 39+ encodeURIComponent(标题),& # 39;_ blank & # 39, 'toolbar=yes,location=yes,directories = no,status=no,menubar=yes,scrollbars=yes,resizable=no,copyhistory=yes,width=600,height=450,top=100,left = 350 & # 39)}共享信息设置:

分享的风格包括图片、标题和介绍。

这个信息不是在分享的时候设置的,而是爬虫直接抓取的分享链接页头中预置的分享信息。头部的配置如下

& lt元属性= & # 34;og:locale & # 34;内容= & # 34;en-US & # 34;& gt& lt元属性= & # 34;og:type & # 34;内容= & # 34;网站& # 34;& gt& lt元属性= & # 34;og:title & # 34;内容= & # 34;realme Holi Game & # 34& gt& lt元属性= & # 34;og:image & # 34;内容= & # 34;xx.jpg & # 34& gt& lt元属性= & # 34;og:描述& # 34;内容= & # 34;你好世界& # 34;& gtTwitter分享触发分享:

& lta href = & # 34JavaScript:void(0)& # 34;@ click = & # 34twShare & # 34& gtTwitter共享</a & gt;tw share(){ let content = & # 39;'window . open(` https://Twitter . com/share?text = $ { encodeURIComponent(data . title)} & URL = $ { encodeURIComponent(urlStr)} `,& # 39;_ blank & # 39, 'toolbar=yes,location=yes,directories = no,status=no,menubar=yes,scrollbars=yes,resizable=no,copyhistory=yes,width=600,height=450,top=100,left = 350 & # 39)}共享信息设置:

分享的风格包括图片、标题和介绍。

这个信息不是在分享的时候设置的,而是爬虫直接抓取的分享链接页头中预置的分享信息。头部的配置如下

<meta name="twitter:title" content="realme Holi Game"><meta name="twitter:description" content="content"><meta name="twitter:image" content="xx.jpg"><meta name="twitter:card" content="summary">

免责声明:本站所有文章内容,图片,视频等均是来源于用户投稿和互联网及文摘转载整编而成,不代表本站观点,不承担相关法律责任。其著作权各归其原作者或其出版社所有。如发现本站有涉嫌抄袭侵权/违法违规的内容,侵犯到您的权益,请在线联系站长,一经查实,本站将立刻删除。

作者:美站资讯,如若转载,请注明出处:https://www.meizw.com/n/357873.html

发表回复

登录后才能评论