我正在尝试消除 Twitter 小部件中的回复和转发。到目前为止,以下代码不起作用:
从 widget.js 的第 1967 行开始:
var F = /twitter\.com(\:\d{2,4})?\/intent\/(\w+)/,
A = {
tweet: true,
retweet: false,
reply:false,
favorite: true
},
而 html 页面正文中的这段代码同样不起作用:
<script type="text/javascript">
new TWTR.Widget({
version: 2,
type: 'search',
search: 'blahblahblah', // This shows all tweets with the hashtag #blahblahblah.
interval: 3000,
title: '',
subject: '',
width: 'auto',
height: 544,
theme: {
shell: {
background: '#cccccc',
color: '#ffffff'
},
tweets: {
background: '#ffffff',
color: '#5e6a71',
links: '#aa0828',
reply:false,
retweet:false
}
},
features: {
scrollbar: false,
loop: true,
live: true,
hashtags: true,
timestamp: true,
avatars: true,
behavior: 'default'
}
}).render().start();
</script>
对此的任何帮助将不胜感激。
最佳答案
要消除转发,请尝试在搜索字符串中添加“-RT”。
关于javascript - 试图消除 Twitter 小部件中的回复和转发,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9793017/