<?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; Php</title>
	<atom:link href="http://www.antonioz.com/category/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.antonioz.com</link>
	<description>What I think, What I write</description>
	<lastBuildDate>Sun, 05 Feb 2012 01:14:46 +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>Image Head Fixed</title>
		<link>http://www.antonioz.com/2007/10/11/image-head-fixed/</link>
		<comments>http://www.antonioz.com/2007/10/11/image-head-fixed/#comments</comments>
		<pubDate>Thu, 11 Oct 2007 14:00:54 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[wordpress]]></category>
		<category><![CDATA[fix]]></category>
		<category><![CDATA[image head]]></category>

		<guid isPermaLink="false">http://www.antonioz.com/2007/10/11/image-head-fixed/</guid>
		<description><![CDATA[升级wp2.3以后，原先的image head的插件一直无法使用，原因是部分函数的变化，导致插件无法读出标题。 看了wp官方的一个帖子后，找到一个解决办法，将 PLAIN TEXT PHP: the_title&#40;'-image-'&#41;; 改成 PLAIN TEXT PHP: echo ImageHeadline_render&#40;''.$post-&#62;post_title.''&#41;; 至少这一方法对我有效，但是否会出现问题还不得而知。 &#169; Antonio 在 苟世录 写了一篇名为 Image Head Fixed 的日志 &#124; 暂时还没有留言，您来踩一脚？ 觉得不错加入您的 美味书签 再看看Technorati上是不是有链接指向此篇日志 想看更多 ? 浏览下关于 wordpress 的文章.]]></description>
			<content:encoded><![CDATA[<p class='fp'>升级wp2.3以后，原先的image head的插件一直无法使用，原因是部分函数的变化，导致插件无法读出标题。</p>
<p>看了wp官方的<a href="http://wordpress.org/support/topic/135591">一个帖子</a>后，找到一个解决办法，将</p>
<div class="igBar"><span id="lphp-3"><a href="#" onclick="javascript:showCodeTxt('php-3'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-3">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">the_title<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">'-image-'</span><span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p>
改成</p>
<div class="igBar"><span id="lphp-4"><a href="#" onclick="javascript:showCodeTxt('php-4'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-4">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><a href="http://www.php.net/echo"><span style="color:#000066;">echo</span></a> ImageHeadline_render<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">''</span>.<span style="color:#0000FF;">$post</span>-&gt;<span style="color:#006600;">post_title</span>.<span style="color:#FF0000;">''</span><span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>至少这一方法对我有效，但是否会出现问题还不得而知。</p>
</p>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Antonio 在 <a href="http://www.antonioz.com">苟世录</a> 写了一篇名为 <a href="http://www.antonioz.com/2007/10/11/image-head-fixed/">Image Head Fixed</a> 的日志 |
	  <a href="http://www.antonioz.com/2007/10/11/image-head-fixed/#comments">暂时还没有留言，您来踩一脚？</a></p>
	<p>觉得不错加入您的 <a href="http://del.icio.us/post?url=http://www.antonioz.com/2007/10/11/image-head-fixed/&amp;title=Image Head Fixed">美味书签</a></p>
	<p>再看看<a href="http://www.technorati.com/search/http://www.antonioz.com/2007/10/11/image-head-fixed/" title="Search on Technorati">Technorati</a>上是不是有链接指向此篇日志</p>
	<p>想看更多 ? 浏览下关于 <a href="http://www.antonioz.com/category/php/wordpress/" title="查看 wordpress 中的全部文章" rel="category tag">wordpress</a> 的文章.</p>]]></content:encoded>
			<wfw:commentRss>http://www.antonioz.com/2007/10/11/image-head-fixed/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress 2.3</title>
		<link>http://www.antonioz.com/2007/09/26/wordpress-23/</link>
		<comments>http://www.antonioz.com/2007/09/26/wordpress-23/#comments</comments>
		<pubDate>Wed, 26 Sep 2007 14:51:25 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[wordpress]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[upgrade]]></category>

		<guid isPermaLink="false">http://www.antonioz.com/2007/09/26/wordpress-23/</guid>
		<description><![CDATA[上周wordpress已经在为发布2.3做准备了，这几天一直有事没顾得上关注它了，今天升级以后发现很多函数都有改动，导致很多插件无法正常调用函数，所以如果你的插件安装的很多，或者不是很迫切需要升级新的版本，我觉得还是停留在2.2以下比较好。 2.3以后wordpress有自己的tag系统了，感觉是由那个tag插件演变而来。而使用tag需要在非默认模板下稍作改动 在 PLAIN TEXT PHP: Posted in &#60;?php the_category&#40;', '&#41; ?&#62; 前 加入 PLAIN TEXT PHP: &#60;?php the_tags&#40;'Tags: ', ', ', '&#60;br /&#62;'&#41;; ?&#62; &#169; Antonio 在 苟世录 写了一篇名为 WordPress 2.3 的日志 &#124; 暂时还没有留言，您来踩一脚？ 觉得不错加入您的 美味书签 再看看Technorati上是不是有链接指向此篇日志 想看更多 ? &#8230; <a href="http://www.antonioz.com/2007/09/26/wordpress-23/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p class='fp'>上周wordpress已经在为发布2.3做准备了，这几天一直有事没顾得上关注它了，今天升级以后发现很多函数都有改动，导致很多插件无法正常调用函数，所以如果你的插件安装的很多，或者不是很迫切需要升级新的版本，我觉得还是停留在2.2以下比较好。</p>
<p>2.3以后wordpress有自己的tag系统了，感觉是由那个tag插件演变而来。而使用tag需要在非默认模板下稍作改动<br />
在
<div class="igBar"><span id="lphp-7"><a href="#" onclick="javascript:showCodeTxt('php-7'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-7">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">Posted in <span style="color:#000000; font-weight:bold;">&lt;?php</span> the_category<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">', '</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#000000; font-weight:bold;">?&gt;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p>前</p>
<p>加入</p>
<div class="igBar"><span id="lphp-8"><a href="#" onclick="javascript:showCodeTxt('php-8'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-8">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#000000; font-weight:bold;">&lt;?php</span> the_tags<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">'Tags: '</span>, <span style="color:#FF0000;">', '</span>, <span style="color:#FF0000;">'&lt;br /&gt;'</span><span style="color:#006600; font-weight:bold;">&#41;</span>; <span style="color:#000000; font-weight:bold;">?&gt;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
</p>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Antonio 在 <a href="http://www.antonioz.com">苟世录</a> 写了一篇名为 <a href="http://www.antonioz.com/2007/09/26/wordpress-23/">WordPress 2.3</a> 的日志 |
	  <a href="http://www.antonioz.com/2007/09/26/wordpress-23/#comments">暂时还没有留言，您来踩一脚？</a></p>
	<p>觉得不错加入您的 <a href="http://del.icio.us/post?url=http://www.antonioz.com/2007/09/26/wordpress-23/&amp;title=WordPress 2.3">美味书签</a></p>
	<p>再看看<a href="http://www.technorati.com/search/http://www.antonioz.com/2007/09/26/wordpress-23/" title="Search on Technorati">Technorati</a>上是不是有链接指向此篇日志</p>
	<p>想看更多 ? 浏览下关于 <a href="http://www.antonioz.com/category/php/wordpress/" title="查看 wordpress 中的全部文章" rel="category tag">wordpress</a> 的文章.</p>]]></content:encoded>
			<wfw:commentRss>http://www.antonioz.com/2007/09/26/wordpress-23/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress的adsense点击率</title>
		<link>http://www.antonioz.com/2007/07/31/adsense-hits-of-wordpress/</link>
		<comments>http://www.antonioz.com/2007/07/31/adsense-hits-of-wordpress/#comments</comments>
		<pubDate>Tue, 31 Jul 2007 03:04:37 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.antonioz.com/2007/07/31/adsense-hits-of-wordpress/</guid>
		<description><![CDATA[在用MT一个月的时间里，页面google adsense的点击率是用wordpress的4倍以上，除了某一关键字排名突然考前的原因外，我觉得还是页面打开速率。 从统计的数据来看，WordPress的页面浏览量比MT要小一个档次，很大的原因是页面打开的速率慢，MT静态页面打开只需要2秒，而wordpress则可能需要5秒以上，如果使用插件比较多，JS加载量大话，页面打开更慢，于是访问用户几乎只打开一个页面就离开了，adsense的点击量可想而知了。 个人建议，如果在wordpress的博客上投放google adsense尽量少使用需要JS加载的插件和框架，特别是加载外部的JS。同时adsense的代码最好div起来，以免adsense加载过慢影响页面打开的速度。 wordpress,adsense &#169; Antonio 在 苟世录 写了一篇名为 WordPress的adsense点击率 的日志 &#124; 暂时还没有留言，您来踩一脚？ 觉得不错加入您的 美味书签 再看看Technorati上是不是有链接指向此篇日志 想看更多 ? 浏览下关于 wordpress 的文章.]]></description>
			<content:encoded><![CDATA[<p class='fp'>在用<a href="http://www.antonioz.com/category/movable-type/">MT</a>一个月的时间里，页面google adsense的点击率是用wordpress的4倍以上，除了某一关键字排名突然考前的原因外，我觉得还是页面打开速率。</p>
<p>从统计的数据来看，<a href="http://www.antonioz.com/category/php/wordpress/">WordPress</a>的页面浏览量比MT要小一个档次，很大的原因是页面打开的速率慢，MT静态页面打开只需要2秒，而wordpress则可能需要5秒以上，如果使用插件比较多，JS加载量大话，页面打开更慢，于是访问用户几乎只打开一个页面就离开了，adsense的点击量可想而知了。</p>
<p>个人建议，如果在wordpress的博客上投放google adsense尽量少使用需要JS加载的插件和框架，特别是加载外部的JS。同时adsense的代码最好div起来，以免adsense加载过慢影响页面打开的速度。</p>
<p><tags>wordpress,adsense</tags></p>
</p>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Antonio 在 <a href="http://www.antonioz.com">苟世录</a> 写了一篇名为 <a href="http://www.antonioz.com/2007/07/31/adsense-hits-of-wordpress/">WordPress的adsense点击率</a> 的日志 |
	  <a href="http://www.antonioz.com/2007/07/31/adsense-hits-of-wordpress/#comments">暂时还没有留言，您来踩一脚？</a></p>
	<p>觉得不错加入您的 <a href="http://del.icio.us/post?url=http://www.antonioz.com/2007/07/31/adsense-hits-of-wordpress/&amp;title=WordPress的adsense点击率">美味书签</a></p>
	<p>再看看<a href="http://www.technorati.com/search/http://www.antonioz.com/2007/07/31/adsense-hits-of-wordpress/" title="Search on Technorati">Technorati</a>上是不是有链接指向此篇日志</p>
	<p>想看更多 ? 浏览下关于 <a href="http://www.antonioz.com/category/php/wordpress/" title="查看 wordpress 中的全部文章" rel="category tag">wordpress</a> 的文章.</p>]]></content:encoded>
			<wfw:commentRss>http://www.antonioz.com/2007/07/31/adsense-hits-of-wordpress/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>又回到了wordpress</title>
		<link>http://www.antonioz.com/2007/07/27/back-to-wordpress/</link>
		<comments>http://www.antonioz.com/2007/07/27/back-to-wordpress/#comments</comments>
		<pubDate>Fri, 27 Jul 2007 07:03:51 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.antonioz.com/2007/07/27/back-to-wordpress/</guid>
		<description><![CDATA[用了一个月的Movable Type还是不能使用，又回到wordpress阵营。 相对来说MT操作起来比较复杂，与wordpress不同的地方比较多，特别是修改模板，更适于web设计师，像我这样的半吊子，实在无法胜任。再者还是资源贫乏，网上很多MT资源不是失效或者已经没有再开发了。虽然升级到MT4后稍有改观，但MT已不如往昔风光。MT在英文语系还有不少支持者，但中文网络，使用和推广的人员更少。 wordpress还是更容易让人上手，现在可能着重要解决的问题是对服务器消耗和缓存的处理。 wordpress &#169; Antonio 在 苟世录 写了一篇名为 又回到了wordpress 的日志 &#124; 暂时还没有留言，您来踩一脚？ 觉得不错加入您的 美味书签 再看看Technorati上是不是有链接指向此篇日志 想看更多 ? 浏览下关于 wordpress 的文章.]]></description>
			<content:encoded><![CDATA[<p class='fp'>用了一个月的<a href="http://www.antonioz.com/category/movable-type/">Movable Type</a>还是不能使用，又回到wordpress阵营。</p>
<p>相对来说MT操作起来比较复杂，<a href="http://www.antonioz.com/2007/06/27/the-difference-of-mt-and-wp/">与wordpress不同的地方</a>比较多，特别是修改模板，更适于web设计师，像我这样的半吊子，实在无法胜任。再者还是资源贫乏，网上很多MT资源不是失效或者已经没有再开发了。虽然<a href="http://www.antonioz.com/2007/07/17/upgrade-to-mt4/">升级到MT4</a>后稍有改观，但MT已不如往昔风光。MT在英文语系还有不少支持者，但中文网络，使用和推广的人员更少。</p>
<p><img src="http://www.antonioz.com/wp-admin/images/wordpress-logo.png" alt="wordpress" /></p>
<p>wordpress还是更容易让人上手，现在可能着重要解决的问题是对服务器消耗和缓存的处理。</p>
<p><tags>wordpress</tags></p>
</p>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Antonio 在 <a href="http://www.antonioz.com">苟世录</a> 写了一篇名为 <a href="http://www.antonioz.com/2007/07/27/back-to-wordpress/">又回到了wordpress</a> 的日志 |
	  <a href="http://www.antonioz.com/2007/07/27/back-to-wordpress/#comments">暂时还没有留言，您来踩一脚？</a></p>
	<p>觉得不错加入您的 <a href="http://del.icio.us/post?url=http://www.antonioz.com/2007/07/27/back-to-wordpress/&amp;title=又回到了wordpress">美味书签</a></p>
	<p>再看看<a href="http://www.technorati.com/search/http://www.antonioz.com/2007/07/27/back-to-wordpress/" title="Search on Technorati">Technorati</a>上是不是有链接指向此篇日志</p>
	<p>想看更多 ? 浏览下关于 <a href="http://www.antonioz.com/category/php/wordpress/" title="查看 wordpress 中的全部文章" rel="category tag">wordpress</a> 的文章.</p>]]></content:encoded>
			<wfw:commentRss>http://www.antonioz.com/2007/07/27/back-to-wordpress/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MT和WP的不同</title>
		<link>http://www.antonioz.com/2007/06/27/the-difference-of-mt-and-wp/</link>
		<comments>http://www.antonioz.com/2007/06/27/the-difference-of-mt-and-wp/#comments</comments>
		<pubDate>Tue, 26 Jun 2007 16:01:22 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[Movable Type]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.antonioz.com/2007/06/27/mt%e5%92%8cwp%e7%9a%84%e4%b8%8d%e5%90%8c/</guid>
		<description><![CDATA[首先一点，发布方式不同。 MT支持完全静态发布，也就是全静态的html或者php文件格式；WP只能使用动态发布，但可以用rewrite使url地址伪静态。两者各有优缺点，全静态发布，使浏览页面的速度变化，也有利于搜索引擎的优化，不过大量生成时会对服务器造成很大的负担，我这几天修改url，就让CPU消耗过大，而被暂停过，同时模板修改后必须把整个博客重建才能达到修改的效果。动态发布，使用伪静态一样对搜索引擎比较友好，修改页面时也能即时生效，但WP对于访问量大的博客的负载比较差，每日IP上千后很容易造成服务器资源的耗损，这也是我转到MT的主要原因。 再者，整个模板体系不同。 MT相对来说要复杂些。默认情况下，MT使用到的模板都是独立的，无通用文件，修改时需要将所有的模板都做调整。使用css来控制整体结构，一般的模板资源只提供css文件。WP的模板有通用的head,foot，调用也比较方便。从操作来说，wp要简便些。 支持度也不同。 WP明显占有绝对的优势，插件，模板等等的资源比较丰富。而MT就比较贫乏些。 使用后的体会，MT操作稍微麻烦些，但看过些使用指导一般都可以熟悉。由于资源较少，如果你想在MT上做更多的自定义模块，可能需要有一些的使用经验和修改技能。 wordpress,movable-type &#169; Antonio 在 苟世录 写了一篇名为 MT和WP的不同 的日志 &#124; 暂时还没有留言，您来踩一脚？ 觉得不错加入您的 美味书签 再看看Technorati上是不是有链接指向此篇日志 想看更多 ? 浏览下关于 Movable Type, wordpress 的文章.]]></description>
			<content:encoded><![CDATA[<p class='fp'>首先一点，发布方式不同。 MT支持完全静态发布，也就是全静态的html或者php文件格式；WP只能使用动态发布，但可以用rewrite使url地址伪静态。两者各有优缺点，全静态发布，使浏览页面的速度变化，也有利于<a href="http://www.antonioz.com/seo/">搜索引擎的优化</a>，不过大量生成时会对服务器造成很大的负担，我这几天<a href="http://www.antonioz.com/2007/06/26/hard-work/">修改url</a>，就让CPU消耗过大，而被暂停过，同时模板修改后必须把整个博客重建才能达到修改的效果。动态发布，使用伪静态一样对搜索引擎比较友好，修改页面时也能即时生效，但WP对于访问量大的博客的负载比较差，每日IP上千后很容易造成服务器资源的耗损，这也是我转到MT的主要原因。  </p>
<p>再者，整个模板体系不同。 MT相对来说要复杂些。默认情况下，MT使用到的模板都是独立的，无通用文件，修改时需要将所有的模板都做调整。使用css来控制整体结构，一般的模板资源只提供css文件。WP的模板有通用的head,foot，调用也比较方便。从操作来说，wp要简便些。  </p>
<p>支持度也不同。 WP明显占有绝对的优势，插件，模板等等的资源比较丰富。而MT就比较贫乏些。  </p>
<p>使用后的体会，MT操作稍微麻烦些，但看过些使用指导一般都可以熟悉。由于资源较少，如果你想在MT上做更多的自定义模块，可能需要有一些的使用经验和修改技能。</p>
<p><tags>wordpress,movable-type</tags></p>
</p>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Antonio 在 <a href="http://www.antonioz.com">苟世录</a> 写了一篇名为 <a href="http://www.antonioz.com/2007/06/27/the-difference-of-mt-and-wp/">MT和WP的不同</a> 的日志 |
	  <a href="http://www.antonioz.com/2007/06/27/the-difference-of-mt-and-wp/#comments">暂时还没有留言，您来踩一脚？</a></p>
	<p>觉得不错加入您的 <a href="http://del.icio.us/post?url=http://www.antonioz.com/2007/06/27/the-difference-of-mt-and-wp/&amp;title=MT和WP的不同">美味书签</a></p>
	<p>再看看<a href="http://www.technorati.com/search/http://www.antonioz.com/2007/06/27/the-difference-of-mt-and-wp/" title="Search on Technorati">Technorati</a>上是不是有链接指向此篇日志</p>
	<p>想看更多 ? 浏览下关于 <a href="http://www.antonioz.com/category/movable-type/" title="查看 Movable Type 中的全部文章" rel="category tag">Movable Type</a>, <a href="http://www.antonioz.com/category/php/wordpress/" title="查看 wordpress 中的全部文章" rel="category tag">wordpress</a> 的文章.</p>]]></content:encoded>
			<wfw:commentRss>http://www.antonioz.com/2007/06/27/the-difference-of-mt-and-wp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress注入bug</title>
		<link>http://www.antonioz.com/2007/05/18/wordpress-inject-bug/</link>
		<comments>http://www.antonioz.com/2007/05/18/wordpress-inject-bug/#comments</comments>
		<pubDate>Fri, 18 May 2007 05:50:12 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.antonioz.com/2007/05/18/wordpress-inject-bug/</guid>
		<description><![CDATA[3月份升级wordpress的时候曾发生过一次模板危机，此前升级过一个高危版本，这里有官方修改记录和非官方的安全报告。 最近又遭遇了一次模本注入的世间，提醒下，如果你使用高危版本的wordpress或者使用2.0.5版，检查下你的网页源文件，是否有带“display:none”的隐藏链接，务必尽快升级至最新版本。 WordPress,注入,bug &#169; Antonio 在 苟世录 写了一篇名为 WordPress注入bug 的日志 &#124; 2 位朋友对此篇日志有兴趣 觉得不错加入您的 美味书签 再看看Technorati上是不是有链接指向此篇日志 想看更多 ? 浏览下关于 wordpress 的文章.]]></description>
			<content:encoded><![CDATA[<p class='fp'>3月份升级wordpress的时候曾发生过一次<a href="http://www.antonioz.com/2007/03/20/template-conjuncture/">模板危机</a>，此前升级过一个<a href="http://www.antonioz.com/2007/03/04/wordpress-dangerous-version/">高危版本</a>，这里有<a href="http://trac.wordpress.org/changeset/4665">官方修改记录</a>和<a href="http://secunia.com/advisories/23587/">非官方的安全报告</a>。</p>
<p>最近又遭遇了一次模本注入的世间，提醒下，如果你使用高危版本的wordpress或者使用2.0.5版，检查下你的网页源文件，是否有带“display:none”的隐藏链接，务必尽快升级至最新版本。</p>
<p><tags>WordPress,注入,bug</tags></p>
</p>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Antonio 在 <a href="http://www.antonioz.com">苟世录</a> 写了一篇名为 <a href="http://www.antonioz.com/2007/05/18/wordpress-inject-bug/">WordPress注入bug</a> 的日志 |
	  <a href="http://www.antonioz.com/2007/05/18/wordpress-inject-bug/#comments">2 位朋友对此篇日志有兴趣</a></p>
	<p>觉得不错加入您的 <a href="http://del.icio.us/post?url=http://www.antonioz.com/2007/05/18/wordpress-inject-bug/&amp;title=WordPress注入bug">美味书签</a></p>
	<p>再看看<a href="http://www.technorati.com/search/http://www.antonioz.com/2007/05/18/wordpress-inject-bug/" title="Search on Technorati">Technorati</a>上是不是有链接指向此篇日志</p>
	<p>想看更多 ? 浏览下关于 <a href="http://www.antonioz.com/category/php/wordpress/" title="查看 wordpress 中的全部文章" rel="category tag">wordpress</a> 的文章.</p>]]></content:encoded>
			<wfw:commentRss>http://www.antonioz.com/2007/05/18/wordpress-inject-bug/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>WordPress2.2</title>
		<link>http://www.antonioz.com/2007/05/16/wordpress22/</link>
		<comments>http://www.antonioz.com/2007/05/16/wordpress22/#comments</comments>
		<pubDate>Wed, 16 May 2007 04:34:22 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.antonioz.com/2007/05/16/wordpress22/</guid>
		<description><![CDATA[这次wordpress升级以后好像解决了MySQL 4.1的乱码问题，在wp-config中多了一行， PLAIN TEXT PHP: define&#40;'DB_CHARSET', 'utf8'&#41;; 以后每次升级就不用再改wp-db了。 这次修改的文件蛮多的，推荐全部覆盖（wp-content可删除）。 更多新功能可以阅读官方报告。 补充：升级的时候发现一个奇怪的编码问题，本博客用的是UTF-8字符集，数据是从mysql4.0转移至mysql4.1的，数据库中读post表可以看到汉字，但其他直接在mysql4.1下安装的wordpress是用的默认字符集latin1_swedish_ci,与至于post表里的汉字全是乱码，而页面上的字符却是正常，连备份的数据也是乱码，不知何故，正在寻找原因。 特安装了一个WP2.1的版本然后升级，将文件全部覆盖，所以问题出在wp-includes/wp-db.php，如果用原先的文件，页面是显示汉字的，如果覆盖了新的就会成乱码。 Update: 2.2版的wordpress好像在分页上有新的改动，导致默认的default模板报错，错误源在wp-include/link-template.php 444行。升级时可能需要注意下此问题。我用了WP-PageNavi，所以未出问题。 修补：将分页修改下 把 PLAIN TEXT PHP: &#60;?php posts_nav_link&#40;'', __&#40;''&#41;, __&#40;'&#38;laquo; Previous entries'&#41;&#41;; ?&#62; &#160; &#160; &#160; &#160; &#60;?php posts_nav_link&#40;' &#38;#183; ', __&#40;''&#41;, __&#40;''&#41;&#41;; ?&#62; &#160; &#160; &#8230; <a href="http://www.antonioz.com/2007/05/16/wordpress22/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p class='fp'>这次wordpress升级以后好像解决了<a href="http://www.antonioz.com/2005/12/03/mysql41%e4%b8%8b%e7%9a%84%e4%b9%b1%e7%a0%81%e9%97%ae%e9%a2%98/">MySQL 4.1的乱码问题</a>，在wp-config中多了一行，</p>
<div class="igBar"><span id="lphp-12"><a href="#" onclick="javascript:showCodeTxt('php-12'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-12">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><a href="http://www.php.net/define"><span style="color:#000066;">define</span></a><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">'DB_CHARSET'</span>, <span style="color:#FF0000;">'utf8'</span><span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>以后每次升级就不用再改wp-db了。</p>
<p>这次修改的文件蛮多的，推荐全部覆盖（wp-content可删除）。</p>
<p>更多新功能可以阅读<a href="http://wordpress.org/development/2007/05/wordpress-22/">官方报告</a>。</p>
<p>补充：升级的时候发现一个奇怪的编码问题，<a href="http://www.antonioz.com/">本博客</a>用的是UTF-8字符集，数据是<a href="http://www.antonioz.com/2006/01/09/mysql41%e7%9a%84%e4%b9%b1%e7%a0%81%e5%a4%84%e7%90%86%e6%96%b9%e6%b3%95/">从mysql4.0转移至mysql4.1的</a>，数据库中读post表可以看到汉字，但其他直接在mysql4.1下安装的wordpress是用的默认字符集latin1_swedish_ci,与至于post表里的汉字全是乱码，而页面上的字符却是正常，连备份的数据也是乱码，不知何故，正在寻找原因。<br />
特安装了一个WP2.1的版本然后升级，将文件全部覆盖，所以问题出在wp-includes/wp-db.php，如果用原先的文件，页面是显示汉字的，如果覆盖了新的就会成乱码。</p>
<p>Update: 2.2版的wordpress好像在分页上有新的改动，导致默认的default模板报错，错误源在wp-include/link-template.php 444行。升级时可能需要注意下此问题。我用了<a href="http://www.antonioz.com/2005/12/08/wp-pagenavi/">WP-PageNavi</a>，所以未出问题。</p>
<p>修补：将分页修改下<br />
把</p>
<div class="igBar"><span id="lphp-13"><a href="#" onclick="javascript:showCodeTxt('php-13'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-13">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#000000; font-weight:bold;">&lt;?php</span> posts_nav_link<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">''</span>, __<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">''</span><span style="color:#006600; font-weight:bold;">&#41;</span>, __<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">'&amp;laquo; Previous entries'</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#41;</span>; <span style="color:#000000; font-weight:bold;">?&gt;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#000000; font-weight:bold;">&lt;?php</span> posts_nav_link<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">' &amp;#183; '</span>, __<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">''</span><span style="color:#006600; font-weight:bold;">&#41;</span>, __<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">''</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#41;</span>; <span style="color:#000000; font-weight:bold;">?&gt;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#000000; font-weight:bold;">&lt;?php</span> posts_nav_link<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">''</span>, __<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">'Next entries &amp;raquo;'</span><span style="color:#006600; font-weight:bold;">&#41;</span>, __<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">''</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#41;</span>; <span style="color:#000000; font-weight:bold;">?&gt;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p>
<strong><br />
改成</strong></p>
<div class="igBar"><span id="lphp-14"><a href="#" onclick="javascript:showCodeTxt('php-14'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-14">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;div <span style="color:#000000; font-weight:bold;">class</span>=<span style="color:#FF0000;">"navigation"</span>&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;div <span style="color:#000000; font-weight:bold;">class</span>=<span style="color:#FF0000;">"alignleft"</span>&gt;&lt;?php next_posts_link<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">'&amp;laquo; Previous Entries'</span><span style="color:#006600; font-weight:bold;">&#41;</span> ?&gt;&lt;/div&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;div <span style="color:#000000; font-weight:bold;">class</span>=<span style="color:#FF0000;">"alignright"</span>&gt;&lt;?php previous_posts_link<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#FF0000;">'Next Entries &amp;raquo;'</span><span style="color:#006600; font-weight:bold;">&#41;</span> ?&gt;&lt;/div&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; &lt;/div&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p><del datetime="2007-05-17T02:42:45+00:00">又发现一个奇怪的问题，我的feed出问题了，<a href="http://www.antonioz.com/feed">http://www.antonioz.com/feed</a> 这个feed是正常的，<a href="http://www.antonioz.com/feed/">http://www.antonioz.com/feed/</a> 这个却挂了，搞不懂了多一个斜杠就出错，怪不得这两天订阅自己的feed没更新了。</del></p>
<p>重新覆盖了一遍好像恢复了。</p>
<p><tags>wordpress,升级</tags></p>
</p>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Antonio 在 <a href="http://www.antonioz.com">苟世录</a> 写了一篇名为 <a href="http://www.antonioz.com/2007/05/16/wordpress22/">WordPress2.2</a> 的日志 |
	  <a href="http://www.antonioz.com/2007/05/16/wordpress22/#comments">4 位朋友对此篇日志有兴趣</a></p>
	<p>觉得不错加入您的 <a href="http://del.icio.us/post?url=http://www.antonioz.com/2007/05/16/wordpress22/&amp;title=WordPress2.2">美味书签</a></p>
	<p>再看看<a href="http://www.technorati.com/search/http://www.antonioz.com/2007/05/16/wordpress22/" title="Search on Technorati">Technorati</a>上是不是有链接指向此篇日志</p>
	<p>想看更多 ? 浏览下关于 <a href="http://www.antonioz.com/category/php/wordpress/" title="查看 wordpress 中的全部文章" rel="category tag">wordpress</a> 的文章.</p>]]></content:encoded>
			<wfw:commentRss>http://www.antonioz.com/2007/05/16/wordpress22/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Better Feed</title>
		<link>http://www.antonioz.com/2007/04/20/better-feed/</link>
		<comments>http://www.antonioz.com/2007/04/20/better-feed/#comments</comments>
		<pubDate>Fri, 20 Apr 2007 02:55:24 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.antonioz.com/2007/04/20/better-feed/</guid>
		<description><![CDATA[突然对博客的feed感兴趣了，捣鼓了下Better Feed这个插件，在feed里。 所以特意介绍了下这个插件，顺便在feedburner上看看输出的效果。 安装是在太简单了，直接上传到plugins目录然后激活下就可以了。 不过有更多自定义的操作，作者提供的版权是英文的，需要讲Custom Strings后的设置稍作修改，这里帖下我做的修改，记得php文件保存的时候要选用utf8格式，否则输出的就是乱码。 PLAIN TEXT PHP: $wp_ozh_betterfeed&#91;'footer'&#93; = &#60;&#60;&#60;FEEDFOOT &#160; &#160; &#60;p&#62;%%readmore%% &#160; &#160; &#60;hr noshade style="margin:0;height:1px" /&#62; &#160; &#160; &#60;p&#62;&#38;copy; %%author_nick%% 在 &#60;a href="%%blogurl%%"&#62;%%blogname%%&#60;/a&#62; 写了一篇名为 &#60;a href="%%posturl%%"&#62;%%posttitle%%&#60;/a&#62; 的日志 &#124; &#160; &#160;&#160; &#160;&#60;a href="%%posturl%%#comments"&#62;%%comments_text%%&#60;/a&#62;&#60;/p&#62; &#160; &#160; &#60;p&#62;觉得不错加入您的 &#8230; <a href="http://www.antonioz.com/2007/04/20/better-feed/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p class='fp'>突然对博客的feed感兴趣了，捣鼓了下<a href="http://frenchfragfactory.net/ozh/my-projects/wordpress-plugin-better-feed-rss/">Better Feed</a>这个插件，在<a href="http://www.antonioz.com/feed/">feed</a>里。</p>
<p>所以特意介绍了下这个插件，顺便在<a href="http://www.feedburner.com/">feedburner</a>上看看输出的效果。 <img src='http://www.antonioz.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>安装是在太简单了，直接上传到plugins目录然后激活下就可以了。</p>
<p>不过有更多自定义的操作，作者提供的版权是英文的，需要讲Custom Strings后的设置稍作修改，这里帖下我做的修改，记得php文件保存的时候要选用utf8格式，否则输出的就是乱码。</p>
<div class="igBar"><span id="lphp-16"><a href="#" onclick="javascript:showCodeTxt('php-16'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-16">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#0000FF;">$wp_ozh_betterfeed</span><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#FF0000;">'footer'</span><span style="color:#006600; font-weight:bold;">&#93;</span> = &lt;&lt;&lt;FEEDFOOT</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &lt;p&gt;%%readmore%%</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &lt;hr noshade style=<span style="color:#FF0000;">"margin:0;height:1px"</span> /&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &lt;p&gt;&amp;copy; %%author_nick%% 在 &lt;a href=<span style="color:#FF0000;">"%%blogurl%%"</span>&gt;%%blogname%%&lt;/a&gt; 写了一篇名为 &lt;a href=<span style="color:#FF0000;">"%%posturl%%"</span>&gt;%%posttitle%%&lt;/a&gt; 的日志 |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp;&lt;a href=<span style="color:#FF0000;">"%%posturl%%#comments"</span>&gt;%%comments_text%%&lt;/a&gt;&lt;/p&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &lt;p&gt;觉得不错加入您的 &lt;a href=<span style="color:#FF0000;">"http://del.icio.us/post?url=%%posturl%%&amp;amp;title=%%posttitle%%"</span>&gt;美味书签&lt;/a&gt;&lt;/p&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &lt;p&gt;再看看&lt;a href=<span style="color:#FF0000;">"http://www.technorati.com/search/%%posturl%%"</span> title=<span style="color:#FF0000;">"Search on Technorati"</span>&gt;Technorati&lt;/a&gt;上是不是有链接指向此篇日志&lt;/p&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &lt;p&gt;想看更多 ? 浏览下关于 %%categorylinks%% 的文章.&lt;/p&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p><tags>feed,wordpress</tags></p>
</p>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Antonio 在 <a href="http://www.antonioz.com">苟世录</a> 写了一篇名为 <a href="http://www.antonioz.com/2007/04/20/better-feed/">Better Feed</a> 的日志 |
	  <a href="http://www.antonioz.com/2007/04/20/better-feed/#comments">已有一位感兴趣的朋友留言了</a></p>
	<p>觉得不错加入您的 <a href="http://del.icio.us/post?url=http://www.antonioz.com/2007/04/20/better-feed/&amp;title=Better Feed">美味书签</a></p>
	<p>再看看<a href="http://www.technorati.com/search/http://www.antonioz.com/2007/04/20/better-feed/" title="Search on Technorati">Technorati</a>上是不是有链接指向此篇日志</p>
	<p>想看更多 ? 浏览下关于 <a href="http://www.antonioz.com/category/php/wordpress/" title="查看 wordpress 中的全部文章" rel="category tag">wordpress</a> 的文章.</p>]]></content:encoded>
			<wfw:commentRss>http://www.antonioz.com/2007/04/20/better-feed/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

