<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: 缓存 js 输出</title>
	<atom:link href="http://justmymemo.com/2008/11/cache-js-output.html/feed" rel="self" type="application/rss+xml" />
	<link>http://justmymemo.com/2008/11/cache-js-output.html</link>
	<description>Just My Memo in Life</description>
	<lastBuildDate>Thu, 26 Aug 2010 04:17:30 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
	<item>
		<title>By: Centeur</title>
		<link>http://justmymemo.com/2008/11/cache-js-output.html/comment-page-1#comment-212</link>
		<dc:creator>Centeur</dc:creator>
		<pubDate>Fri, 15 May 2009 06:07:47 +0000</pubDate>
		<guid isPermaLink="false">http://justmymemo.com/?p=304#comment-212</guid>
		<description>@&lt;a href=&quot;#comment-208&quot; rel=&quot;nofollow&quot;&gt;Xiao3:&lt;/a&gt;新建个模板文件
&lt;?php
/*
Template Name: Elsewhere
*/
?&gt;

&lt;?php get_header(); ?&gt;

...

&lt;?php
$num = 40;
$uri = &#039;http://friendfeed.com/embed/widget/centeur?v=2&amp;num=&#039;.$num.&#039;&amp;hide_logo=1&amp;hide_comments_likes=1&amp;hide_subscribe=1&amp;width=515&#039;;
if (!$output = wp_cache_get(&#039;friendfeed&#039;, &#039;js_cache&#039;)){
if (!class_exists(&#039;Snoopy&#039;)) include_once(ABSPATH . WPINC . &#039;/class-snoopy.php&#039;);
$snoopy = new Snoopy;
$snoopy-&gt;fetch($uri);
$temp = $snoopy-&gt;results;
$output = str_replace(array(&#039;http://friendfeed.com/static/images/icons/twitter.png&#039;,&#039;http://friendfeed.com/static/images/icons/reddit.png&#039;),array(&#039;http://justmymemo.com/wp-content/themes/firebug/images/twitter.png&#039;,&#039;http://justmymemo.com/wp-content/themes/firebug/images/reddit.png&#039;),$temp); //替换一些图片
wp_cache_add(&#039;friendfeed&#039;, $output, &#039;js_cache&#039;, 3600);
}
?&gt;
&lt;script type=&quot;text/javascript&quot;&gt;&lt;?php echo $output; ?&gt;&lt;/script&gt;

...

&lt;?php get_sidebar(); ?&gt;
&lt;?php get_footer(); ?&gt;

再新建一个页面，取名 Elsewhere 即可。</description>
		<content:encoded><![CDATA[<p>@<a href="#comment-208" rel="nofollow">Xiao3:</a>新建个模板文件<br />
< ?php<br />
/*<br />
Template Name: Elsewhere<br />
*/<br />
?></p>
<p>< ?php get_header(); ?></p>
<p>&#8230;</p>
<p>< ?php<br />
$num = 40;<br />
$uri = 'http://friendfeed.com/embed/widget/centeur?v=2&amp;num='.$num.'&amp;hide_logo=1&amp;hide_comments_likes=1&amp;hide_subscribe=1&amp;width=515';<br />
if (!$output = wp_cache_get('friendfeed', 'js_cache')){<br />
if (!class_exists('Snoopy')) include_once(ABSPATH . WPINC . '/class-snoopy.php');<br />
$snoopy = new Snoopy;<br />
$snoopy->fetch($uri);<br />
$temp = $snoopy->results;<br />
$output = str_replace(array(&#8216;http://friendfeed.com/static/images/icons/twitter.png&#8217;,'http://friendfeed.com/static/images/icons/reddit.png&#8217;),array(&#8216;http://justmymemo.com/wp-content/themes/firebug/images/twitter.png&#8217;,'http://justmymemo.com/wp-content/themes/firebug/images/reddit.png&#8217;),$temp); //替换一些图片<br />
wp_cache_add(&#8216;friendfeed&#8217;, $output, &#8216;js_cache&#8217;, 3600);<br />
}<br />
?><br />
<script type="text/javascript">< ?php echo $output; ?></script></p>
<p>&#8230;</p>
<p>< ?php get_sidebar(); ?><br />
< ?php get_footer(); ?></p>
<p>再新建一个页面，取名 Elsewhere 即可。</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Xiao3</title>
		<link>http://justmymemo.com/2008/11/cache-js-output.html/comment-page-1#comment-208</link>
		<dc:creator>Xiao3</dc:creator>
		<pubDate>Fri, 15 May 2009 01:35:27 +0000</pubDate>
		<guid isPermaLink="false">http://justmymemo.com/?p=304#comment-208</guid>
		<description>能教教我怎么弄你的那个elsewhere 页面吗？我也想弄一个！我不会代码！</description>
		<content:encoded><![CDATA[<p>能教教我怎么弄你的那个elsewhere 页面吗？我也想弄一个！我不会代码！</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Centeur</title>
		<link>http://justmymemo.com/2008/11/cache-js-output.html/comment-page-1#comment-164</link>
		<dc:creator>Centeur</dc:creator>
		<pubDate>Mon, 10 Nov 2008 23:38:52 +0000</pubDate>
		<guid isPermaLink="false">http://justmymemo.com/?p=304#comment-164</guid>
		<description>@&lt;a href=&quot;#comment-163&quot; rel=&quot;nofollow&quot;&gt;西岸:&lt;/a&gt;过奖，我最近正在较系统的学习 PHP，呵呵。</description>
		<content:encoded><![CDATA[<p>@<a href="#comment-163" rel="nofollow">西岸:</a>过奖，我最近正在较系统的学习 PHP，呵呵。</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: 西岸</title>
		<link>http://justmymemo.com/2008/11/cache-js-output.html/comment-page-1#comment-163</link>
		<dc:creator>西岸</dc:creator>
		<pubDate>Mon, 10 Nov 2008 11:04:41 +0000</pubDate>
		<guid isPermaLink="false">http://justmymemo.com/?p=304#comment-163</guid>
		<description>高手就是高手啊。</description>
		<content:encoded><![CDATA[<p>高手就是高手啊。</p>
]]></content:encoded>
	</item>
</channel>
</rss>
