jQuery DomWindow不适用于Twitter链接+链接的最后一部分像普通链接一样工作 [英] jQuery DomWindow doesn't work for twitter links + last portion of links work like normal links

查看:101
本文介绍了jQuery DomWindow不适用于Twitter链接+链接的最后一部分像普通链接一样工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用此脚本(用于页面上所有链接的jquery DomWindow )在RSS显示器中( http://www.javascriptkit.com/dhtmltutors/googleajaxfeed3 .shtml ),我发现了两个奇怪的问题:

I'm using this script (jquery DomWindow for all links on webpage) in a RSS displayer (http://www.javascriptkit.com/dhtmltutors/googleajaxfeed3.shtml) and I discovered two strange problems:

1)它适用于大多数链接,但不适用于Twitter状态链接(例如 http://twitter.com/IraHeatBeat/statuses/48228573173121024 )-它显示DOMWindow,但将其留为空白.

1)It works for most links, but doesn't work for the links of twitter statuses (e.g http://twitter.com/IraHeatBeat/statuses/48228573173121024) - it displays the DOMWindow, but leaves it blank.

2)生成的RSS链接的最后一部分的工作方式与普通链接相同(没有DOMWindow,仅在该链接之后).例如,PM体育作品的链接就像普通链接一样:

2)The last portion of generated RSS links work like normal links (no DOMWindow, just follows the link). E.g the links for PM sport work like normal links:

<div>ERR Sport
<script type="text/javascript">
    //USAGE SYNTAX: new rssdisplayer("divid", "rssurl", numberofitems, "displayoptions")
    new rssdisplayer("ERR_sport", "http://sport.etv.ee/xml/spordiuudised.php", 12, "date")
</script>
    The Basketball Jones
<script type="text/javascript">
    //USAGE SYNTAX: new rssdisplayer("divid", "rssurl", numberofitems, "displayoptions")
    new rssdisplayer("TBJ", "http://feeds.feedburner.com/TheBasketballJones", 5, "date")
</script>
    PM Sport
<script type="text/javascript">
    //USAGE SYNTAX: new rssdisplayer("divid", "rssurl", numberofitems, "displayoptions")
    new rssdisplayer("PMsport", "http://sport.postimees.ee//rss/", 5, "date")
</script></div>

有解决方案吗?

推荐答案

好吧,我为第二个问题创建了一种解决方法,方法是在末尾添加一个RSS feed脚本(例如问题).

Ok, I created a workaround for the second problem by adding a hidden div at the end with an RSS feed script (like the ones in the code part of the question) in it.

但是仍然存在DOMWindow不显示Twitter页面的问题.
而且我还发现它不允许通过DOMWindow访问Facebook,而只是显示指向Facebook的链接.

But there's still the problem with the DOMWindow not displaying Twitter pages.
And I also discovered that it doesn't allow visiting Facebook via the DOMWindow, it just displays the link to Facebook.

有人吗?

这篇关于jQuery DomWindow不适用于Twitter链接+链接的最后一部分像普通链接一样工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆