<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>等待-放飞梦想 &#187; load</title>
	<atom:link href="http://leotheme.cn/tag/load/feed" rel="self" type="application/rss+xml" />
	<link>http://leotheme.cn</link>
	<description>勤现在-乐将来</description>
	<lastBuildDate>Fri, 03 Feb 2012 12:32:54 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>jquery ajax方法如load,get等 在Chrome下失效的问题</title>
		<link>http://leotheme.cn/javascript/jquery-ajax-load-get-in-chrome.html</link>
		<comments>http://leotheme.cn/javascript/jquery-ajax-load-get-in-chrome.html#comments</comments>
		<pubDate>Tue, 12 Oct 2010 00:09:07 +0000</pubDate>
		<dc:creator>Await</dc:creator>
				<category><![CDATA[前端交互]]></category>
		<category><![CDATA[Ajax]]></category>
		<category><![CDATA[chrome]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[load]]></category>

		<guid isPermaLink="false">http://leotheme.cn/?p=835</guid>
		<description><![CDATA[最近碰到一个问题，发现jquery在chrome 中， ajax的load get等方法完全失效。 代码如下： function getHtml(url,ctner){ //alert(ctner); //$.get(url,function(data) {$(ctner).html(data);}, &#34;text&#34;); try{ $(ctner).load(url); } catch(e)&#160;{ alert(url + &#34;读取错误&#34;); } } 症状： 其实语句是执行了，如上面的代码，TRY的时候并没有抛出错误，但返回的内容就是空值。 百度了半天没发现解决方法。 后来GOOGLE了一下老外的内容，才发现问题的症结 http://forum.jquery.com/topic/load-and-ajax-not-working-on-google-chrome 原来是Chrome 5+里面对非针对服务端的Ajax调用做了严格的限制，如果是在SERVER端调用就没有问题了。。。。。。无语 作个记录。我昨正也遇到这个问题了； 原文：http://hi.baidu.com/barkbread/blog/item/acc0bdd4b786e70ca08bb73f.html 相关文章2009-11-30 -- 不刷新（AJAX）获取文章的内容 (53)相信大家都知道AJAX评论这玩意。AJAX评论带来了很多好处，不用在刷新页面就能发表评论。实时提交，实时显示。很多人都用上了都给自己的BLOG上添加了这样的功能。方法在这就不说了，很多人都作了详细的讲...2011-09-08 -- jQuery中queue和dequeue的用法 (1)今天在做右下角那个静止的工具栏时遇到了一个问题。鼠标放上去的时候，要让周围的4个按钮按顺序显示出来，移开的时候要按顺序隐藏。左思右想发现用animate的回调函数方式来写比较麻烦。于是百度了下，发现j...2011-08-17 -- Flight主题更新 (16)这几天收到有些童鞋反应主题在wp3.2版本后台不能快速编缉文章，不能上传图片。抽空看了下，是JQ库版本冲突引起，现已更新。请移步到wopus主题站下载更新后的版本。也可以通过115网盘下载。...2010-11-24 -- JQ弹出层插件(tipsWindow 2.8) (154)已更新为2.7...2010-10-12 -- 分享Flight主题中的焦点图（基于JQ） (22)关于这个焦点图没啥说的了，网上太多了。但自己一直没找到个合适的。现在的这个是Dreamy主题中的升级版，虽然看起来一模一样。其实做了很多扩展，优化了结构和JS部分。可以选择切换方式（左右滚动，上下滚动...<table class="wumii-related-items" cellspacing="0" cellpadding="3" border="0"  style="clear: both;">
    
    <tr>
        <td colspan="5"><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
        <tr>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important;">
                    <a target="_blank" title="不刷新（AJAX）获取文章的内容" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/04/22/6196490.png" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">不刷新（AJAX）获取文章的内容</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="jQuery 实现 tab 切换一例" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-tab.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/04/22/6197250.png" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">jQuery 实现 tab 切换一例</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="用jQuery实现个性有序列表" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-to-sequential-list.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/04/22/6197275.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">用jQuery实现个性有序列表</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="jQuery性能优化指南" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-xingnen-youhua.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">jQuery性能优化指南</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="用jquery写一个简单的菜单伸缩效果" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-for-nav-slide.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/04/22/6197279.png" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">用jquery写一个简单的菜单伸缩效果</font>
                    </a>
                </td>
        </tr>
    
    <tr>
        <td colspan="5" align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>最近碰到一个问题，发现jquery在chrome 中， ajax的load get等方法完全失效。 代码如下：</p>
<div class="hl-surround"><ol class="hl-main ln-show" title="Double click to hide line number." ondblclick = "linenumber(this)"><li class="hl-firstline"><span style="color: Green;">function</span><span style="color: Gray;"> </span><span style="color: Blue;">getHtml</span><span style="color: Olive;">(</span><span style="color: Blue;">url</span><span style="color: Gray;">,</span><span style="color: Blue;">ctner</span><span style="color: Olive;">){</span></li>
<li><span style="color: #ffa500;">//alert(ctner);</span></li>
<li><span style="color: #ffa500;">//$.get(url,function(data) {$(ctner).html(data);}, &quot;text&quot;);</span></li>
<li><span style="color: Green;">try</span><span style="color: Olive;">{</span><span style="color: Gray;"> $</span><span style="color: Olive;">(</span><span style="color: Blue;">ctner</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">load</span><span style="color: Olive;">(</span><span style="color: Blue;">url</span><span style="color: Olive;">)</span><span style="color: Gray;">; </span><span style="color: Olive;">}</span></li>
<li><span style="color: Green;">catch</span><span style="color: Olive;">(</span><span style="color: Blue;">e</span><span style="color: Olive;">)</span><span style="color: Gray;">&nbsp;</span><span style="color: Olive;">{</span><span style="color: Gray;"> </span><span style="color: Blue;">alert</span><span style="color: Olive;">(</span><span style="color: Blue;">url</span><span style="color: Gray;"> + </span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">读取错误</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">; </span><span style="color: Olive;">}</span></li>
<li><span style="color: Olive;">}</span></li></ol></div>
<p>症状： 其实语句是执行了，如上面的代码，TRY的时候并没有抛出错误，但返回的内容就是空值。</p>
<p>百度了半天没发现解决方法。 后来GOOGLE了一下老外的内容，才发现问题的症结<br />
<span id="more-835"></span><br />
<a href="http://forum.jquery.com/topic/load-and-ajax-not-working-on-google-chrome">http://forum.jquery.com/topic/load-and-ajax-not-working-on-google-chrome</a></p>
<p>原来是Chrome 5+里面对非针对服务端的Ajax调用做了严格的限制，如果是在SERVER端调用就没有问题了。。。。。。无语</p>
<p>作个记录。我昨正也遇到这个问题了；</p>
<p>原文：<a href="http://hi.baidu.com/barkbread/blog/item/acc0bdd4b786e70ca08bb73f.html">http://hi.baidu.com/barkbread/blog/item/acc0bdd4b786e70ca08bb73f.html</a></p>
<table class="wumii-related-items" cellspacing="0" cellpadding="3" border="0"  style="clear: both;">
    
    <tr>
        <td colspan="5"><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
        <tr>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important;">
                    <a target="_blank" title="不刷新（AJAX）获取文章的内容" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/04/22/6196490.png" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">不刷新（AJAX）获取文章的内容</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="jQuery 实现 tab 切换一例" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-tab.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/04/22/6197250.png" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">jQuery 实现 tab 切换一例</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="用jQuery实现个性有序列表" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-to-sequential-list.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/04/22/6197275.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">用jQuery实现个性有序列表</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="jQuery性能优化指南" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-xingnen-youhua.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">jQuery性能优化指南</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="用jquery写一个简单的菜单伸缩效果" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-for-nav-slide.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/04/22/6197279.png" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">用jquery写一个简单的菜单伸缩效果</font>
                    </a>
                </td>
        </tr>
    
    <tr>
        <td colspan="5" align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table><h3  class="related_post_title">相关文章</h3><ul class="related_post"><li>2009-11-30 -- <a href="http://leotheme.cn/javascript/ajax-load-post-content.html" title="不刷新（AJAX）获取文章的内容">不刷新（AJAX）获取文章的内容</a> (53)<br /><small>相信大家都知道AJAX评论这玩意。AJAX评论带来了很多好处，不用在刷新页面就能发表评论。实时提交，实时显示。很多人都用上了都给自己的BLOG上添加了这样的功能。方法在这就不说了，很多人都作了详细的讲...</small></li><li>2011-09-08 -- <a href="http://leotheme.cn/javascript/jquery%e4%b8%adqueue%e5%92%8cdequeue%e7%9a%84%e7%94%a8%e6%b3%95.html" title="jQuery中queue和dequeue的用法">jQuery中queue和dequeue的用法</a> (1)<br /><small>今天在做右下角那个静止的工具栏时遇到了一个问题。鼠标放上去的时候，要让周围的4个按钮按顺序显示出来，移开的时候要按顺序隐藏。左思右想发现用animate的回调函数方式来写比较麻烦。于是百度了下，发现j...</small></li><li>2011-08-17 -- <a href="http://leotheme.cn/wordpress/flight-update.html" title="Flight主题更新">Flight主题更新</a> (16)<br /><small>这几天收到有些童鞋反应主题在wp3.2版本后台不能快速编缉文章，不能上传图片。抽空看了下，是JQ库版本冲突引起，现已更新。请移步到wopus主题站下载更新后的版本。也可以通过115网盘下载。...</small></li><li>2010-11-24 -- <a href="http://leotheme.cn/javascript/jquery-plugins-tipswindow-2-0.html" title="JQ弹出层插件(tipsWindow 2.8)">JQ弹出层插件(tipsWindow 2.8)</a> (154)<br /><small>已更新为2.7...</small></li><li>2010-10-12 -- <a href="http://leotheme.cn/javascript/flight-theme-jquery-ifocus.html" title="分享Flight主题中的焦点图（基于JQ）">分享Flight主题中的焦点图（基于JQ）</a> (22)<br /><small>关于这个焦点图没啥说的了，网上太多了。但自己一直没找到个合适的。现在的这个是Dreamy主题中的升级版，虽然看起来一模一样。其实做了很多扩展，优化了结构和JS部分。可以选择切换方式（左右滚动，上下滚动...</small></li></ul>]]></content:encoded>
			<wfw:commentRss>http://leotheme.cn/javascript/jquery-ajax-load-get-in-chrome.html/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>不刷新（AJAX）获取文章的内容</title>
		<link>http://leotheme.cn/javascript/ajax-load-post-content.html</link>
		<comments>http://leotheme.cn/javascript/ajax-load-post-content.html#comments</comments>
		<pubDate>Mon, 30 Nov 2009 15:27:19 +0000</pubDate>
		<dc:creator>Await</dc:creator>
				<category><![CDATA[前端交互]]></category>
		<category><![CDATA[Ajax]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[load]]></category>
		<category><![CDATA[WP相关]]></category>

		<guid isPermaLink="false">http://leotheme.cn/?p=782</guid>
		<description><![CDATA[相信大家都知道AJAX评论这玩意。AJAX评论带来了很多好处，不用在刷新页面就能发表评论。实时提交，实时显示。很多人都用上了都给自己的BLOG上添加了这样的功能。方法在这就不说了，很多人都作了详细的讲解。在这想跟大家分享下。AJAX加载文章的内容。当然，这里还是基于JQ的load方法来实现。OK，来看效果： 首先，定义三个变量： var objTag= $(&#34;.post&#34;);//定义要获取内容所在的节点 var&#160;num= objTag.length;//定义节点的数量 var&#160;_cache=new Object;//建立一个缓存对像 然后构建一个加载的函数： function loadentry(n){ &#160; &#160; var&#160;_url=$(objTag[n]).children(&#34;.archive-post-title&#34;).children(&#34;h2&#34;).children(&#34;a&#34;).attr(&#34;href&#34;);//定义要加载文章的地址 &#160; &#160; $('&#60;div class=&#34;details&#34;&#62;&#60;div style=&#34;width:160px;margin-top:8px;padding:0 2px;font-size:12px;background: #01E343; color:#FFF;&#34;&#62;正在加载文章内容，请稍等！&#60;/div&#62;&#60;/div&#62;').insertBefore($(objTag[n]).children(&#34;.singledata&#34;));//插入提示信息 &#160; &#160; if(_cache[_url]==null){//判断是否有缓存 &#160; &#160; &#160; &#160; $(objTag[n]).children(&#34;.details&#34;).load(_url+&#34; .post .entry&#34;,function(){ &#160; &#160; &#160; &#160; &#160; &#160; _cache[_url]=$(objTag[n]).children(&#34;.details&#34;).html(); &#160; &#160; &#160; &#160; &#160; &#160; $('&#60;span class=&#34;archive-arrow&#34;&#62;&#60;span title=&#34;收起全文&#34; class=&#34;hide fRight&#34; onclick=&#34;closentry(&#38;quot;'+n+'&#38;quot;);&#34;&#62;收起全文↑&#60;/span&#62;&#60;/span&#62;').insertAfter($(objTag[n]).children(&#34;.details&#34;)); &#160; &#160; &#160; [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">jquery ajax方法如load,get等 在Chrome下失效的问题</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fclick-title-display-content.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">简单几步显示/隐藏文章内容</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fwordpress-bookmarkandshare.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">AddThis——为你的文章添加一个Share按钮</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjsonp-get-json-data.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Jsonp 方式跨域获取 json 数据</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fothes%2Flaogonghelaopodegushi.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">说真的，这篇文章很有”意思”？！</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>相信大家都知道AJAX评论这玩意。AJAX评论带来了很多好处，不用在刷新页面就能发表评论。实时提交，实时显示。很多人都用上了都给自己的BLOG上添加了这样的功能。方法在这就不说了，很多人都作了详细的讲解。在这想跟大家分享下。AJAX加载文章的内容。当然，这里还是基于JQ的load方法来实现。OK，来看效果：<br />
<span id="more-782"></span><br />
<img src="http://leotheme.cn/wp-content/uploads/2009/11/load1.png" alt="load1" title="load1" width="503" height="91" class="alignnone size-full wp-image-783" /></p>
<p><img src="http://leotheme.cn/wp-content/uploads/2009/11/load2.png" alt="load2" title="load2" width="535" height="99" class="alignnone size-full wp-image-784" /></p>
<p><img src="http://leotheme.cn/wp-content/uploads/2009/11/load3.png" alt="load3" title="load3" width="471" height="109" class="alignnone size-full wp-image-785" /></p>
<p>首先，定义三个变量：</p>
<div class="hl-surround"><ol class="hl-main ln-show" title="Double click to hide line number." ondblclick = "linenumber(this)"><li class="hl-firstline"><span style="color: Green;">var</span><span style="color: Gray;"> </span><span style="color: Blue;">objTag</span><span style="color: Gray;">= $</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.post</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">;</span><span style="color: #ffa500;">//定义要获取内容所在的节点</span></li>
<li><span style="color: Green;">var</span><span style="color: Gray;">&nbsp;</span><span style="color: Blue;">num</span><span style="color: Gray;">= </span><span style="color: Blue;">objTag</span><span style="color: Gray;">.</span><span style="color: Blue;">length</span><span style="color: Gray;">;</span><span style="color: #ffa500;">//定义节点的数量</span></li>
<li><span style="color: Green;">var</span><span style="color: Gray;">&nbsp;</span><span style="color: Blue;">_cache</span><span style="color: Gray;">=</span><span style="color: Green;">new</span><span style="color: Gray;"> </span><span style="color: Blue;">Object</span><span style="color: Gray;">;</span><span style="color: #ffa500;">//建立一个缓存对像</span></li></ol></div>
<p>然后构建一个加载的函数：</p>
<div class="hl-surround"><ol class="hl-main ln-show" title="Double click to hide line number." ondblclick = "linenumber(this)"><li class="hl-firstline"><span style="color: Green;">function</span><span style="color: Gray;"> </span><span style="color: Blue;">loadentry</span><span style="color: Olive;">(</span><span style="color: Blue;">n</span><span style="color: Olive;">){</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; </span><span style="color: Green;">var</span><span style="color: Gray;">&nbsp;</span><span style="color: Blue;">_url</span><span style="color: Gray;">=$</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-post-title</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">h2</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">a</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">attr</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">href</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">;</span><span style="color: #ffa500;">//定义要加载文章的地址</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: #8b0000;">'</span><span style="color: Red;">&lt;div class=&quot;details&quot;&gt;&lt;div style=&quot;width:160px;margin-top:8px;padding:0 2px;font-size:12px;background: #01E343; color:#FFF;&quot;&gt;正在加载文章内容，请稍等！&lt;/div&gt;&lt;/div&gt;</span><span style="color: #8b0000;">'</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">insertBefore</span><span style="color: Olive;">(</span><span style="color: Gray;">$</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.singledata</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">))</span><span style="color: Gray;">;</span><span style="color: #ffa500;">//插入提示信息</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; </span><span style="color: Green;">if</span><span style="color: Olive;">(</span><span style="color: Blue;">_cache</span><span style="color: Olive;">[</span><span style="color: Blue;">_url</span><span style="color: Olive;">]</span><span style="color: Gray;">==</span><span style="color: Green;">null</span><span style="color: Olive;">){</span><span style="color: #ffa500;">//判断是否有缓存</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; &nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.details</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">load</span><span style="color: Olive;">(</span><span style="color: Blue;">_url</span><span style="color: Gray;">+</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;"> .post .entry</span><span style="color: #8b0000;">&quot;</span><span style="color: Gray;">,</span><span style="color: Green;">function</span><span style="color: Olive;">(){</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </span><span style="color: Blue;">_cache</span><span style="color: Olive;">[</span><span style="color: Blue;">_url</span><span style="color: Olive;">]</span><span style="color: Gray;">=$</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.details</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">html</span><span style="color: Olive;">()</span><span style="color: Gray;">;</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: #8b0000;">'</span><span style="color: Red;">&lt;span class=&quot;archive-arrow&quot;&gt;&lt;span title=&quot;收起全文&quot; class=&quot;hide fRight&quot; onclick=&quot;closentry(&amp;quot;</span><span style="color: #8b0000;">'</span><span style="color: Gray;">+</span><span style="color: Blue;">n</span><span style="color: Gray;">+</span><span style="color: #8b0000;">'</span><span style="color: Red;">&amp;quot;);&quot;&gt;收起全文↑&lt;/span&gt;&lt;/span&gt;</span><span style="color: #8b0000;">'</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">insertAfter</span><span style="color: Olive;">(</span><span style="color: Gray;">$</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.details</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">))</span><span style="color: Gray;">;</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; &nbsp; &nbsp; </span><span style="color: Olive;">})</span><span style="color: Gray;">;</span><span style="color: #ffa500;">//加载文章内容</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; </span><span style="color: Olive;">}</span><span style="color: Green;">else</span><span style="color: Olive;">{</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; &nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-post-title</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-arrow</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">remove</span><span style="color: Olive;">()</span><span style="color: Gray;">;</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; &nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.details</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">html</span><span style="color: Olive;">(</span><span style="color: Blue;">_cache</span><span style="color: Olive;">[</span><span style="color: Blue;">_url</span><span style="color: Olive;">])</span><span style="color: Gray;">;</span><span style="color: #ffa500;">//直接显示缓存对像的内容</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; &nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: #8b0000;">'</span><span style="color: Red;">&lt;span class=&quot;archive-arrow&quot;&gt;&lt;span title=&quot;收起全文&quot; class=&quot;hide fRight&quot; onclick=&quot;closentry(&amp;quot;</span><span style="color: #8b0000;">'</span><span style="color: Gray;">+</span><span style="color: Blue;">n</span><span style="color: Gray;">+</span><span style="color: #8b0000;">'</span><span style="color: Red;">&amp;quot;);&quot;&gt;收起全文↑&lt;/span&gt;&lt;/span&gt;</span><span style="color: #8b0000;">'</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">insertAfter</span><span style="color: Olive;">(</span><span style="color: Gray;">$</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.details</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">))</span><span style="color: Gray;">;</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; </span><span style="color: Olive;">}</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-post-title</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-arrow</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">remove</span><span style="color: Olive;">()</span><span style="color: Gray;">;</span></li>
<li><span style="color: Olive;">}</span></li></ol></div>
<p>这部分对于不懂JQ的人来说可能有点复杂。懂JQ的人看起来一定很简单。就是一个对DOM的操作。通过动态的插入清除节点来实现我们需要的效果。关健在于“.load()”的用法。</p>
<p>到这已经实现了加载了。接着需要做个删除也就是收起全文；相比加载，删除要简单的多了，就是直接删除节点就行了。</p>
<div class="hl-surround"><ol class="hl-main ln-show" title="Double click to hide line number." ondblclick = "linenumber(this)"><li class="hl-firstline"><span style="color: Green;">function</span><span style="color: Gray;"> </span><span style="color: Blue;">closentry</span><span style="color: Olive;">(</span><span style="color: Blue;">n</span><span style="color: Olive;">){</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.details</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">animate</span><span style="color: Olive;">({</span><span style="color: Blue;">height</span><span style="color: Gray;">: </span><span style="color: #8b0000;">'</span><span style="color: Red;">toggle</span><span style="color: #8b0000;">'</span><span style="color: Olive;">}</span><span style="color: Gray;">, </span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">slow</span><span style="color: #8b0000;">&quot;</span><span style="color: Gray;">,</span><span style="color: Green;">function</span><span style="color: Olive;">(){</span><span style="color: Gray;">$</span><span style="color: Olive;">(</span><span style="color: Green;">this</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">remove</span><span style="color: Olive;">()})</span><span style="color: Gray;">; </span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-arrow</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">remove</span><span style="color: Olive;">()</span><span style="color: Gray;">;</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: #8b0000;">'</span><span style="color: Red;">&lt;div class=&quot;archive-arrow&quot;&gt;&lt;span title=&quot;阅读全文&quot; class=&quot;show&quot; onclick=&quot;loadentry(&amp;quot;</span><span style="color: #8b0000;">'</span><span style="color: Gray;">+</span><span style="color: Blue;">n</span><span style="color: Gray;">+</span><span style="color: #8b0000;">'</span><span style="color: Red;">&amp;quot;);&quot;&gt;阅读全文↓&lt;/span&gt;&lt;/div&gt;</span><span style="color: #8b0000;">'</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">insertAfter</span><span style="color: Olive;">(</span><span style="color: Gray;">$</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">n</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-post-title</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">p</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">))</span><span style="color: Gray;">;</span></li>
<li><span style="color: Olive;">}</span></li></ol></div>
<p>这段代码就是一个基本的节点操作。在这就不作说明了；当然，最后我们需要插入节点并绑定事件。</p>
<div class="hl-surround"><ol class="hl-main ln-show" title="Double click to hide line number." ondblclick = "linenumber(this)"><li class="hl-firstline"><span style="color: Gray;">$</span><span style="color: Olive;">(</span><span style="color: Teal;">document</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">ready</span><span style="color: Olive;">(</span><span style="color: Green;">function</span><span style="color: Olive;">(){</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; </span><span style="color: Green;">for</span><span style="color: Olive;">(</span><span style="color: Blue;">a</span><span style="color: Gray;">=</span><span style="color: Maroon;">0</span><span style="color: Gray;">;</span><span style="color: Blue;">a</span><span style="color: Gray;">&lt;</span><span style="color: Blue;">num</span><span style="color: Gray;">;</span><span style="color: Blue;">a</span><span style="color: Gray;">++</span><span style="color: Olive;">){</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; &nbsp; &nbsp; $</span><span style="color: Olive;">(</span><span style="color: Blue;">objTag</span><span style="color: Olive;">[</span><span style="color: Blue;">a</span><span style="color: Olive;">])</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-post-title</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">children</span><span style="color: Olive;">(</span><span style="color: #8b0000;">&quot;</span><span style="color: Red;">.archive-arrow</span><span style="color: #8b0000;">&quot;</span><span style="color: Olive;">)</span><span style="color: Gray;">.</span><span style="color: Blue;">append</span><span style="color: Olive;">(</span><span style="color: #8b0000;">'</span><span style="color: Red;">&lt;span class=&quot;show&quot; title=&quot;阅读全文&quot; onclick=&quot;loadentry(&amp;quot;</span><span style="color: #8b0000;">'</span><span style="color: Gray;">+</span><span style="color: Blue;">a</span><span style="color: Gray;">+</span><span style="color: #8b0000;">'</span><span style="color: Red;">&amp;quot;);&quot;&gt;阅读全文↓&lt;/span&gt;</span><span style="color: #8b0000;">'</span><span style="color: Olive;">)</span><span style="color: Gray;">;</span></li>
<li><span style="color: Gray;">&nbsp; &nbsp; </span><span style="color: Olive;">}</span></li>
<li><span style="color: Olive;">})</span><span style="color: Gray;">;</span></li></ol></div>
<p>OK，到这里这个AJAX加载效果就完成了。详细的效果可以点击侧边栏的分类导航。</p>
<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjquery-ajax-load-get-in-chrome.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">jquery ajax方法如load,get等 在Chrome下失效的问题</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fclick-title-display-content.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">简单几步显示/隐藏文章内容</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fwordpress-bookmarkandshare.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">AddThis——为你的文章添加一个Share按钮</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fjsonp-get-json-data.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Jsonp 方式跨域获取 json 数据</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fleotheme.cn%2Fothes%2Flaogonghelaopodegushi.html&from=http%3A%2F%2Fleotheme.cn%2Fjavascript%2Fajax-load-post-content.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">说真的，这篇文章很有”意思”？！</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table><h3  class="related_post_title">相关文章</h3><ul class="related_post"><li>2010-10-12 -- <a href="http://leotheme.cn/javascript/jquery-ajax-load-get-in-chrome.html" title="jquery ajax方法如load,get等 在Chrome下失效的问题">jquery ajax方法如load,get等 在Chrome下失效的问题</a> (4)<br /><small>最近碰到一个问题，发现jquery在chrome 中， ajax的load get等方法完全失效。 代码如下：


function getHtml(url,ctner){
//alert(c...</small></li><li>2008-11-27 -- <a href="http://leotheme.cn/javascript/add-login-window-at-sidebar.html" title="给你的侧边栏添加一个登陆入口">给你的侧边栏添加一个登陆入口</a> (12)<br /><small>个人一直觉得wordpress的登陆很麻烦，要打开一个新窗口才行。而且默认的那个窗口看起来并不怎么漂亮。所以决定给它整整，搞个适合偶主题的登陆框才行。之前我已经写过一篇文章，但那个是用jQuery实现...</small></li><li>2008-09-15 -- <a href="http://leotheme.cn/javascript/jqueryforwpgoodtwo.html" title="jquery基础教程二[伸缩、隔行变色...]">jquery基础教程二[伸缩、隔行变色...]</a> (3)<br /><small>在上一篇介绍中已经讲了一些基本的应用，今天继续。先看一下面这个例子
Demo_5：收缩展开功能[如无法运行请多刷新几次或保存到本地运行]

 
 
 
 
可伸缩块 

 
p,d...</small></li><li>2008-09-11 -- <a href="http://leotheme.cn/javascript/jqueryforwpgoodone.html" title="jquery基础教程一[click,addClass,show,hide]">jquery基础教程一[click,addClass,show,hide]</a> (3)<br /><small>原创内容—转载请说明出处.

jQuery我想很多人都知道，但用WP的好像很少有人说到这个。今天开始和大家一起来研究下如何用jQuery来为我们的WP添加实用的功能。至于jQuery的相关背景和资...</small></li><li>2008-08-28 -- <a href="http://leotheme.cn/wordpress/wordpressjs-jqueryone.html" title="利用WP自带的JS库打造超酷的侧边栏">利用WP自带的JS库打造超酷的侧边栏</a> (6)<br /><small>从这篇文章开始，我们来认识下wordpress自带的JS库，下面这张图是WP自动的JS文件夹。可以看出有很多JS文件，当然包括大名鼎鼎的jquery和prototype。利用这些我们能实现很多很酷的效...</small></li></ul>]]></content:encoded>
			<wfw:commentRss>http://leotheme.cn/javascript/ajax-load-post-content.html/feed</wfw:commentRss>
		<slash:comments>53</slash:comments>
		</item>
	</channel>
</rss>

