<?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>Some reminiscences, some memories &#187; Zend Framework</title>
	<atom:link href="http://www.mikespook.com/index.php/category/php/zend-framework/feed" rel="self" type="application/rss+xml" />
	<link>http://www.mikespook.com</link>
	<description>Just another boring day</description>
	<lastBuildDate>Wed, 08 Feb 2012 09:28:30 +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>Zend Framework 1.8.0 带来的变化</title>
		<link>http://www.mikespook.com/2009/05/zend-framework-180-%e5%b8%a6%e6%9d%a5%e7%9a%84%e5%8f%98%e5%8c%96/</link>
		<comments>http://www.mikespook.com/2009/05/zend-framework-180-%e5%b8%a6%e6%9d%a5%e7%9a%84%e5%8f%98%e5%8c%96/#comments</comments>
		<pubDate>Sun, 03 May 2009 05:46:13 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[变化]]></category>
		<category><![CDATA[自动化]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/?p=294</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
曾经，我很羡慕 Django 等框架那完善的自动化工具。说实话，在 MVC 框架中不停的建立Controller、Action 是一件又枯燥，又麻烦的事情。而且，维护起来也颇费功夫。所以在 ninnypro 中我引入了一个 cli 工具，用于创建 Controller、Action 以及更新 ACL 的资源表。

现在，这些都将成为历史了。

Zend Framework 引入了 Zend_Tool 和 Zend_Application 两个包，用于自动化和快速集成。并且成熟的命令行工具 zf 也可以使用了。例如这里！！

<span class="readmore"><a href="http://www.mikespook.com/2009/05/zend-framework-180-%e5%b8%a6%e6%9d%a5%e7%9a%84%e5%8f%98%e5%8c%96/" title="Zend Framework 1.8.0 带来的变化">阅读全文——共336字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>曾经，我很羡慕 Django 等框架那完善的自动化工具。说实话，在 MVC 框架中不停的建立Controller、Action 是一件又枯燥，又麻烦的事情。而且，维护起来也颇费功夫。所以在 <a href="http://code.google.com/p/ninnypro/">ninnypro</a> 中我引入了一个 cli 工具，用于创建 Controller、Action 以及更新 ACL 的资源表。</p>
<p>现在，这些都将成为历史了。</p>
<p>Zend Framework 引入了 Zend_Tool 和 Zend_Application 两个包，用于自动化和快速集成。并且成熟的命令行工具 zf 也可以使用了。例如<a href="http://devzone.zend.com/article/4524-Zend-Framework-1.8.0-Released">这里</a>！！</p>
<p><img class="alignnone" src="http://framework.zend.com/manual/en/figures/zend.tool.framework.clihelp.png" alt="" width="778" height="497" /></p>
<p>zf 将程序员的关注点聚焦到程序功能和细节的实现，更加的统一和方便。跟 ninnypro 的思路类似，以放弃灵活性为代价，换取约束性和开发速度。</p>
<p>如果我有精力，或许会在此基础上重新建构 ninnypro 吧。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2009/05/zend-framework-180-%e5%b8%a6%e6%9d%a5%e7%9a%84%e5%8f%98%e5%8c%96/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>PHP框架的繁荣是正确的发展方向吗？</title>
		<link>http://www.mikespook.com/2009/02/php%e6%a1%86%e6%9e%b6%e7%9a%84%e7%b9%81%e8%8d%a3%e6%98%af%e6%ad%a3%e7%a1%ae%e7%9a%84%e5%8f%91%e5%b1%95%e6%96%b9%e5%90%91%e5%90%97%ef%bc%9f/</link>
		<comments>http://www.mikespook.com/2009/02/php%e6%a1%86%e6%9e%b6%e7%9a%84%e7%b9%81%e8%8d%a3%e6%98%af%e6%ad%a3%e7%a1%ae%e7%9a%84%e5%8f%91%e5%b1%95%e6%96%b9%e5%90%91%e5%90%97%ef%bc%9f/#comments</comments>
		<pubDate>Tue, 17 Feb 2009 15:52:35 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[框架]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/?p=286</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
这个其实是源于 javaeye 上的这个讨论：http://www.javaeye.com/post/886707。最开始吸引我的是在 rails 板块上诸多专业玩 java 和 ruby 的人是如何评价 php 以及 php 框架的。在讨论中发现有一些值得学习和借鉴的地方。所以推荐大家完整阅读这个帖子。从技术性、知识面和娱乐性来讲，都是质量很高的。

我就简单说一下我对于 php 框架繁荣的看法：

1. “草根阶级”向“企业开发俱乐部”转变的必然途径。

<span class="readmore"><a href="http://www.mikespook.com/2009/02/php%e6%a1%86%e6%9e%b6%e7%9a%84%e7%b9%81%e8%8d%a3%e6%98%af%e6%ad%a3%e7%a1%ae%e7%9a%84%e5%8f%91%e5%b1%95%e6%96%b9%e5%90%91%e5%90%97%ef%bc%9f/" title="PHP框架的繁荣是正确的发展方向吗？">阅读全文——共1313字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>这个其实是源于 javaeye 上的这个讨论：<a href="http://www.javaeye.com/post/886707">http://www.javaeye.com/post/886707</a>。最开始吸引我的是在 rails 板块上诸多专业玩 java 和 ruby 的人是如何评价 php 以及 php 框架的。在讨论中发现有一些值得学习和借鉴的地方。所以推荐大家完整阅读这个帖子。从技术性、知识面和娱乐性来讲，都是质量很高的。</p>
<p>我就简单说一下我对于 php 框架繁荣的看法：<span id="more-286"></span></p>
<p>1. “草根阶级”向“企业开发俱乐部”转变的必然途径。</p>
<p>用 php 的企业多了，市场占有率高了，经济效益就体现出来了。但是仅仅靠做做企业网站，搞搞论坛这个蛋糕还太小。同时 B2B、B2C 的繁荣，自然带来已有网站的改造问题。php 迈着坚定的步伐冲向“俱乐部”大门。但是门卫说了“贫民与狗不得入内”。于是 php 的规范化、可维护性发展如火如荼的展开了。首先是学习 java，从语言层面引入 java 的优点。然后是开发规范的建立，涌现出大批商业框架。包括 php 的后台老板 zend，也推出自己的 Zend Framework。</p>
<p>2. php 从骨子里就是一个善于借鉴吸收的语言。</p>
<p>php 诞生伊始，是 perl 的跟班。后来 perl 跟班作得不爽了，就直接找到 perl 的老大 c 做跟班。这一作就是十几年。从最初跟 perl 学习，到后来跟  c 学习。然后 java 火了，跟  java 学习。再后来框架开发逐渐成为主流的时候，又开始搞有 php 特色的框架主义。当然还是延续原有风格与方法，好的东西一并吸收。吸收不良了再做改造。</p>
<p>3. php 框架是为了让php应用更加简单出现的。</p>
<p>我在 2004 年的时候搞过自己的一个小框架，实际上是整合了大量 pear 包的功能，自己利用 call_user_func_array 函数作为路由解析。使用 smarty 作为前端脚本。虽然有很多不足，但是在给朋友开发的几个项目中，“简单”这个原则体现得非常好。在只有美工和系统管理员的情况下，对网站进行了多次改版。并不是框架让我的朋友快速的学会了 php，而是框架让跳出语言细节的开发成为了可能。php 由于其发展方式决定了没有一个统一的功能调用界面，各种明明方式、调用方式混杂在一起，许多“学院派”对此尤为诟病。但是框架从一个新的高度上统一了这些本不统一的调用。从而使得开发更加简单、快捷。</p>
<p>好吧，最后我再说说许多 javaer 和 rubier 极力想证明的：“php 唯一的好处就是轻快，在套上沉重的框架枷锁后，它将没有任何优势同 java 或者 ruby 竞争。”其实这个问题就像老廖永远打不完的口水仗一样（老廖别急，这里纯粹调节气氛），没有最终的答案。不过有几点可以探讨：</p>
<p>1. php 已经有极高的市场占有率。并且回头客户很多。</p>
<p>2. php 在大型网站的应用不在少数，虽然许多是改造过的 php。</p>
<p>3. 性能在硬件发展迅猛的今天已经不是当年 64K 内存 2MHz 计算能力需要精打细算的年代。有更多事情远比性能重要。曾经道听途说过一种说法“与其高新聘请一个高级人才来优化程序，节约几十万的硬件成本。不如多花点钱用好硬件，弥补程序的不足。”想想也对，人才是在所有开发中最不靠谱的因素。</p>
<p>最后，我想用一句说得已经有点烂的话结束这个讨论：“事物总是在它应该出现的地方出现，应该消失的地方消失。”</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2009/02/php%e6%a1%86%e6%9e%b6%e7%9a%84%e7%b9%81%e8%8d%a3%e6%98%af%e6%ad%a3%e7%a1%ae%e7%9a%84%e5%8f%91%e5%b1%95%e6%96%b9%e5%90%91%e5%90%97%ef%bc%9f/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Zend Framework 1.7.0 已经出来了</title>
		<link>http://www.mikespook.com/2008/11/zend-framework-170-%e5%b7%b2%e7%bb%8f%e5%87%ba%e6%9d%a5%e4%ba%86/</link>
		<comments>http://www.mikespook.com/2008/11/zend-framework-170-%e5%b7%b2%e7%bb%8f%e5%87%ba%e6%9d%a5%e4%ba%86/#comments</comments>
		<pubDate>Tue, 18 Nov 2008 02:17:29 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[New features]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/?p=230</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
http://devzone.zend.com/article/4045-Zend-Framework-1.7.0-is-now-available

新版本放出，除了修复了近三百个 bug 外，还有下面的新功能。



<span class="readmore"><a href="http://www.mikespook.com/2008/11/zend-framework-170-%e5%b7%b2%e7%bb%8f%e5%87%ba%e6%9d%a5%e4%ba%86/" title="Zend Framework 1.7.0 已经出来了">阅读全文——共1666字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p><a href="http://devzone.zend.com/article/4045-Zend-Framework-1.7.0-is-now-available" target="_blank">http://devzone.zend.com/article/4045-Zend-Framework-1.7.0-is-now-available</a></p>
<p>新版本放出，除了修复了近三百个 bug 外，还有下面的新功能。<span id="more-230"></span></p>
<ul class="disc">
<li>Zend_Amf with support for AMF0 and AMF3 protocols</li>
<li>Dojo Toolkit 1.2.1</li>
<li>Support for dijit editor available in the Dojo Toolkit</li>
<li>Zend_Service_Twitter</li>
<li>ZendX_JQuery in extras library</li>
<li>Metadata API in Zend_Cache</li>
<li>Google book search API in Zend_Gdata</li>
<li>Preliminary support for GData Protocol v2 in Zend_Gdata</li>
<li>Support for skip data processing in Zend_Search_Lucene</li>
<li>Support for Open Office XML documents in Zend_Search_Lucene indexer</li>
<li>Performance enhancements in Zend_Loader, Zend_Controller, and server components</li>
<li>Zend_Mail_Storage_Writable_Maildir enhancements for mail delivery</li>
<li>Zend_Tool in incubator</li>
<li>Zend_Text_Table for formatting table using characters</li>
<li>Zend_ProgressBar</li>
<li>Zend_Config_Writer</li>
<li>ZendX_Console_Unix_Process in the extras library</li>
<li>Zend_Db_Table_Select support for Zend_Paginator</li>
<li>Global parameters for routes</li>
<li>Using Chain-Routes for Hostname-Routes via Zend_Config</li>
<li>I18N improvements
<ul>
<li>Application wide locale for all classes</li>
<li>Data retrieving methods are now static</li>
<li>Additional cache handling methods in all I18N classes</li>
<li>Zend_Translate API simplified</li>
</ul>
</li>
<li>File transfer enhancements
<ul>
<li>Support for file elements in subforms</li>
<li>Support for multifile elements</li>
<li>Support for MAX_FILES_SIZE in form</li>
<li>Support for breaking validation chain</li>
<li>Support for translation of failure ,messages</li>
<li>New IsCompressed, IsImage, ExcludeMimeType, ExcludeExtension validators</li>
<li>Support for FileInfo extension in MimeType validator</li>
</ul>
</li>
<li>Zend_Db_Table_Select adapater for Zend_Paginator</li>
<li>Support for custom adapters in Zend_Paginator</li>
<li>More flexible handling of complex types in Zend_Soap</li>
</ul>
<p>可以看到，由于改进了 Zend_Loader 和 Zend_Controller，性能应该会得到提升。</p>
<p>同时通过 Zend_Config_Writera 修改config文件会变得更加容易。</p>
<p>由于有了 Zend_Paginator ，<a href="http://code.google.com/p/ninnypro/" target="_blank">ninnypro</a> 中的分页的 helper 肯定要修改了。</p>
<p>Zend_Tools 也会给 <a href="http://code.google.com/p/ninnypro/" target="_blank">ninnypro</a> 的辅助工具带来一些变化。</p>
<p>Zend_JQuery 将替代 Ninny_View_Helper_Jquery。</p>
<p>呼，突然发现，这么多要跟进的内容。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2008/11/zend-framework-170-%e5%b7%b2%e7%bb%8f%e5%87%ba%e6%9d%a5%e4%ba%86/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>netbeans 6.5 rc 下建立 Zend Framework 项目</title>
		<link>http://www.mikespook.com/2008/10/netbeans-65-rc-%e4%b8%8b%e5%bb%ba%e7%ab%8b-zend-framework-%e9%a1%b9%e7%9b%ae/</link>
		<comments>http://www.mikespook.com/2008/10/netbeans-65-rc-%e4%b8%8b%e5%bb%ba%e7%ab%8b-zend-framework-%e9%a1%b9%e7%9b%ae/#comments</comments>
		<pubDate>Fri, 24 Oct 2008 04:37:13 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[NetBeans]]></category>
		<category><![CDATA[Zend Framework]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/?p=205</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
首先，这不是一个指南，这只是一个简易说明。描述了如何在 netbeans 6.5 rc for php 中建立、开发、调试 Zend Framework 项目。

step by step:

1. 安装 netbeans 6.5 rc for php，由于 netbeans 6.5 rc for php 官方只放出了英文版本。中文版本要在这里下载。

<span class="readmore"><a href="http://www.mikespook.com/2008/10/netbeans-65-rc-%e4%b8%8b%e5%bb%ba%e7%ab%8b-zend-framework-%e9%a1%b9%e7%9b%ae/" title="netbeans 6.5 rc 下建立 Zend Framework 项目">阅读全文——共1782字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>首先，这不是一个指南，这只是一个简易说明。描述了如何在 netbeans 6.5 rc for php 中建立、开发、调试 Zend Framework 项目。</p>
<p>step by step:<span id="more-205"></span></p>
<p>1. 安装 netbeans 6.5 rc for php，由于 netbeans 6.5 rc for php 官方只放出了<a href="http://download.netbeans.org/netbeans/6.5/rc/bundles/netbeans-6.5rc1-php-windows.exe" target="_blank">英文版本</a>。中文版本要在<a href="http://dlc.sun.com.edgesuite.net/netbeans/6.5/rc/" target="_blank">这里下载</a>。</p>
<p>2. 安装 xdebug，这不是必要的一部，不过如果你想在 netbeans 中调试 php。这是非常必要的。相关内容去 <a href="http://xdebug.org/" target="_blank">xdebug 官方网站</a>了解，<a href="http://www.mikespook.com/index.php/archives/34" target="_blank">这里</a>也有简单的说明。</p>
<p>3. 我假设你在安装 netbeans 6.5 rc for php 未遇到任何问题，如果遇到了，请参考 netbeans 的 <a href="http://wiki.netbeans.org/NetBeansUserFAQ#section-NetBeansUserFAQ-Installation" target="_blank">FAQ 关于安装的部分</a>。</p>
<p>4. 打开 netbeans 6.5 rc for php，在菜单中选择“新建项目”。当然更多时候 Ctrl+Shift+N 是一个更好的主意。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_1.jpg"><img class="alignnone size-medium wp-image-208" title="netbeans_for_php_1" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_1.jpg" alt="" width="296" height="128" /></a></p>
<p>5. 选择“PHP 应用程序”点下一步。也可以导入现有的代码，实际上两者并无本质区别。</p>
<p>6. 设置项目的名称以及存储目录。实际上这个存储目录需要将所有项目用到的文件，如代码、文档、配置都包含进去，否则开发时将遇到无穷无尽的从 netbeans 切换到其他工具，再切换回来的情况。而用到的不再进行修改的库文件，反而可以不用包含。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_7.jpg"><img class="alignnone size-medium wp-image-209" title="netbeans_for_php_7" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_7.jpg" alt="" width="148" height="99" /></a></p>
<p>7. 设置好名称和目录后，在“运行配置”中选择项目的部署方式，以及索引文件。通常本地开发网站，默认选择第一种方式即可。这时，netbeans 会默认以项目目录作为 webroot。索引文件可先随意选择一个项目目录中的文件。通常 Zend Framework 开发中 webroot 只是包含 index.php 入口和样式、图片等客户端使用的文件。例如目录“&lt;项目目录&gt;/www”。由于 Zend Framework 部署的特殊性，这里还要做修改。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_2.jpg"><img class="alignnone size-medium wp-image-210" title="netbeans_for_php_2" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_2-300x94.jpg" alt="" width="300" height="94" /></a></p>
<p>8. 在“项目”面板中选择刚才建立的 php 项目，点击鼠标右键选择菜单项“属性”。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_8.jpg"><img class="alignnone size-medium wp-image-211" title="netbeans_for_php_8" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_8-225x300.jpg" alt="" width="225" height="300" /></a></p>
<p>9. 在类别“源”的“Web 根目录”选择你真正的 webroot。例如：&lt;项目目录&gt;/www。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_3.jpg"><img class="alignnone size-medium wp-image-212" title="netbeans_for_php_3" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_3-300x84.jpg" alt="" width="300" height="84" /></a></p>
<p>10. 在“项目属性”的“运行配置”类别中，调整索引文件到 index.php。实际上，如果你完成了 step 9，这里会有一个“不是合法的索引文件”的警告。直到你重新调整索引文件为合法文件。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_4.jpg"><img class="alignnone size-medium wp-image-213" title="netbeans_for_php_4" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_4-300x72.jpg" alt="" width="300" height="72" /></a></p>
<p>11. 在“项目属性”的“PHP 包含路径”中设置你的 Zend Framework 路径。例如从 svn 导出的某个路径 ~/Zend Framework\library。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_5.jpg"><img class="alignnone size-medium wp-image-214" title="netbeans_for_php_5" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_5-300x99.jpg" alt="" width="300" height="99" /></a></p>
<p>12. 至此已经基本设置完成，需要注意的是“项目属性”中的“调试服务器端 PHP”和“调试客户端 JavaScript” 需要勾上才可以正常调试。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_6.jpg"><img class="alignnone size-medium wp-image-215" title="netbeans_for_php_6" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_6-300x90.jpg" alt="" width="300" height="90" /></a></p>
<p>简单测试一下代码编辑和调试的情况：</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_9.jpg"><img class="alignnone size-medium wp-image-216" title="netbeans_for_php_9" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_9-283x300.jpg" alt="" width="283" height="300" /></a></p>
<p>漂亮完整的代码提示，包括方法或属性类型、参数、所在的类名或文件名等等。同时还会解析 phpdoc。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_10.jpg"><img class="alignnone size-medium wp-image-217" title="netbeans_for_php_10" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_10-300x94.jpg" alt="" width="300" height="94" /></a></p>
<p>强大的单步调试，我以前说过 php 让我头疼的就是调试。虽然 xdebug 很完美，但是所有调试器都有这样那样的不足。现在 netbeans 带来的是 java style 的调试方式，很好，很强大。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_11.jpg"><img class="alignnone size-medium wp-image-218" title="netbeans_for_php_11" src="http://www.mikespook.com/wp-content/uploads/2008/10/netbeans_for_php_11-300x176.jpg" alt="" width="300" height="176" /></a></p>
<p>变量的监视信息详实准确，无需再为一个变量的值而 echo 来 var_dump 去了。</p>
<p>总体上来说，netbeans 6.5rc for php 是我见过的比较好的 IDE for php 之一。即便我坚信 IDE is evil ，netbeans for php 也让我眼前一亮。再配合其他插件如 svn、uml、database，已经无需其他工具辅助即可完成 php 日常开发所需。不过试用之后，也发现一些不足的地方：比如有一些提示框中英文混杂在一起；新建 php 工程的向导设置也过于简单，以至于建立 Zend Framework 项目时需要建立好后再次调整项目设置；又比如会莫名其妙的提示一个临时目录下某文件无法访问；再如代码提示时不能正确解析魔法方法，无法提示魔法方法提供的魔法属性等等。不过相信在正式的 6.5 版中这些问题都会一一得到解决，作为一个 rc 版本的软件来说，netbeans 已经做得够好了。</p>
<p>我计划在 PNP-广州 PHP 街坊群中推荐 netbeans 作为初学 Zend Framework 的平台，这样可以利用强大的单步功能，和代码提示功能来学习 Zend Framework，了解 Zend Framework 的运行机制。不知道大家对此有什么看法和意见，欢迎讨论。</p>
<p>PS: 推荐 eclipse 的朋友务必请考虑一下我那只有 512M 内存的本本，当时选择用 netbeans 写 java，就是因为它不是那么消耗内存和 cpu。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2008/10/netbeans-65-rc-%e4%b8%8b%e5%bb%ba%e7%ab%8b-zend-framework-%e9%a1%b9%e7%9b%ae/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Zend_Loader::isReadable 和 is_readable 的区别</title>
		<link>http://www.mikespook.com/2008/09/zend_loaderisreadable-%e5%92%8c-is_readable-%e7%9a%84%e5%8c%ba%e5%88%ab/</link>
		<comments>http://www.mikespook.com/2008/09/zend_loaderisreadable-%e5%92%8c-is_readable-%e7%9a%84%e5%8c%ba%e5%88%ab/#comments</comments>
		<pubDate>Tue, 23 Sep 2008 07:54:36 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[is_readable]]></category>
		<category><![CDATA[Zend_Loader::isReadable]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/?p=190</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
以前分析过 Zend Framework 1.0 的 Zend_Loader；php 内建函数 is_readable 本质上就是调用 filestat.c 的 php_stat 函数，这个在前几天关于 file_exists 和 is_file 的那个 post 中有说过。

今天在群上跟番茄吹水，说起来这个东西。于是又混一篇小记随便吹吹。

以下所有内容，45%是吹水，45%是猜测，10%是从代码中看出来的。

<span class="readmore"><a href="http://www.mikespook.com/2008/09/zend_loaderisreadable-%e5%92%8c-is_readable-%e7%9a%84%e5%8c%ba%e5%88%ab/" title="Zend_Loader::isReadable 和 is_readable 的区别">阅读全文——共884字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>以前分析过 Zend Framework 1.0 的 Zend_Loader；php 内建函数 is_readable 本质上就是调用 filestat.c 的 php_stat 函数，这个在前几天关于 file_exists 和 is_file 的那个 post 中有说过。<br />
今天在群上跟番茄吹水，说起来这个东西。于是又混一篇小记随便吹吹。<br />
以下所有内容，45%是吹水，45%是猜测，10%是从代码中看出来的。<span id="more-190"></span></p>
<p>Zend_Loader:isReadable() 的代码如下：</p>
<div style="background-color:#000000; color: #cccccc"><span style="font-family: monospace;"><span style="color: #ffff00;">150 </span> <span style="color: #80a0ff;">/**</span><br />
<span style="color: #ffff00;">151 </span><span style="color: #80a0ff;"> * Returns TRUE if the $filename is readable, or FALSE otherwise.</span><br />
<span style="color: #ffff00;">152 </span><span style="color: #80a0ff;"> * This function uses the PHP include_path, where PHP&#8217;s is_readable()</span><br />
<span style="color: #ffff00;">153 </span><span style="color: #80a0ff;"> * does not.</span><br />
<span style="color: #ffff00;">154 </span><span style="color: #80a0ff;"> *</span><br />
<span style="color: #ffff00;">155 </span><span style="color: #80a0ff;"> * @param string   $filename</span><br />
<span style="color: #ffff00;">156 </span><span style="color: #80a0ff;"> * @return boolean</span><br />
<span style="color: #ffff00;">157 </span><span style="color: #80a0ff;"> */</span><br />
<span style="color: #ffff00;">158 </span><span style="color: #60ff60;"> public static </span><span style="color: #ff80ff;">function</span> isReadable<span style="color: #ffa500;">(</span><span style="color: #ffff00;">$</span><span style="color: #40ffff;">filename</span><span style="color: #ffa500;">)</span><br />
<span style="color: #ffff00;">159 </span> <span style="color: #ffa500;">{</span><br />
<span style="color: #ffff00;">160 </span> <span style="color: #ffff00;">if</span> <span style="color: #ffa500;">(</span><span style="color: #ffff00;">!</span><span style="color: #ffff00;">$</span><span style="color: #40ffff;">fh</span> <span style="color: #ffff00;">=</span> @<span style="color: #40ffff;">fopen</span><span style="color: #ffa500;">(</span><span style="color: #ffff00;">$</span><span style="color: #40ffff;">filename</span>, &#8216;<span style="color: #ffa0a0;">r</span>&#8216;, <span style="color: #ffa0a0;">true</span><span style="color: #ffa500;">))</span> <span style="color: #ffa500;">{</span><br />
<span style="color: #ffff00;">161 </span> <span style="color: #ffff00;">return</span> <span style="color: #ffa0a0;">false</span>;<br />
<span style="color: #ffff00;">162 </span> <span style="color: #ffa500;">}</span><br />
<span style="color: #ffff00;">163 </span> @<span style="color: #40ffff;">fclose</span><span style="color: #ffa500;">(</span><span style="color: #ffff00;">$</span><span style="color: #40ffff;">fh</span><span style="color: #ffa500;">)</span>;<br />
<span style="color: #ffff00;">164 </span> <span style="color: #ffff00;">return</span> <span style="color: #ffa0a0;">true</span>;<br />
<span style="color: #ffff00;">165 </span><span style="color: #ffa500;"> }</span><br />
</span></div>
<p>可以看到，通过 fopen 来判断是否能访问指定文件。并且 fopen 的第三个参数为 true，也就是说允许判断 include_path 中的文件。这个方法有个显而易见的好处，除了可以判断 include_path 的文件外，还可以使用 http://foobar 或者 ftp://foobar 的 php stream 方式来判断是否可读。也就是说支持远端文件。</p>
<p>而 is_readable 从 php_stat 这个 c 函数的内容上可以看出，是不支持远端文件的。最多支持 file:// 而已。<br />
不过 is_readable 是具有缓存的，也就是说可以用更小的代价去获得文件的访问属性。而 Zend_Loader::isReadable 不但要 fopen，还要 fclose 代价不能说不大了。</p>
<p>至于如何取舍，其实就看具体的需求了。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2008/09/zend_loaderisreadable-%e5%92%8c-is_readable-%e7%9a%84%e5%8c%ba%e5%88%ab/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>编译了 CHM 的 Zend Framework 手册[2008-07-04 更新]</title>
		<link>http://www.mikespook.com/2008/07/%e7%bc%96%e8%af%91%e4%ba%86-chm-%e7%9a%84-zend-framework-%e6%89%8b%e5%86%8c/</link>
		<comments>http://www.mikespook.com/2008/07/%e7%bc%96%e8%af%91%e4%ba%86-chm-%e7%9a%84-zend-framework-%e6%89%8b%e5%86%8c/#comments</comments>
		<pubDate>Fri, 04 Jul 2008 08:00:52 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[chm]]></category>
		<category><![CDATA[手册]]></category>

		<guid isPermaLink="false">http://blog.xxiyy.com/index.php/archives/7</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
[2008-07-04] 中文版本 chm 发布 1 周年，今天截止，中文翻译进度是 71%。同时也编译了英文版本。

中文 Zend Framework 手册 CHM 版本 &#124; 英文 Zend Framework 手册 CHM版本

同时在 SVN 的中文手册目录下增加了 tools 目录，其中包含了正确编译中文 CHM 的说明以及工具。直接访问 SVN 的朋友可以自行编译。

<span class="readmore"><a href="http://www.mikespook.com/2008/07/%e7%bc%96%e8%af%91%e4%ba%86-chm-%e7%9a%84-zend-framework-%e6%89%8b%e5%86%8c/" title="编译了 CHM 的 Zend Framework 手册[2008-07-04 更新]">阅读全文——共727字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>[2008-07-04] 中文版本 chm 发布 1 周年，今天截止，中文翻译进度是 71%。同时也编译了英文版本。<br />
<strong><a href="http://www.mikespook.com/wp-content/uploads/2008/07/zend_framework_zh.zip">中文 Zend Framework 手册 CHM 版本</a> </strong>|<strong> <a href="http://www.mikespook.com/wp-content/uploads/2008/07/zend_framework_en.zip">英文 Zend Framework 手册 CHM版本</a></strong></p>
<p>同时在 SVN 的中文手册目录下增加了 tools 目录，其中包含了正确编译中文 CHM 的说明以及工具。直接访问 SVN 的朋友可以自行编译。</p>
<p><strong><a href="http://www.mikespook.com/wp-content/uploads/2008/07/zend_framework_en.zip"></a></strong><a href="http://www.mikespook.com/wp-content/uploads/2008/07/zend_framework_en.zip"><span id="more-7"></span></a></p>
<hr />[2008-05-20] 新编译了中文版本，同时包含翻译了一部分还未 commit 到 svn 的 xml-rpc 的内容。<br />
<strong><span style="text-decoration: line-through;">中文 Zend Framework 手册 CHM 版本</span><strong><br />
</strong></strong></p>
<hr />[2007-08-20] 中文版仍然无法通过编译，故只更新英文版本。</p>
<p><span style="text-decoration: line-through;"><strong><strong><strong><span class="delete">英文 Zend Framework 手册 CHM</span></strong></strong></strong></span></p>
<hr />[2007-07-04] haohappy 更新了之前乱码的部分，重新编译了中文手册。</p>
<p><span style="text-decoration: line-through;"><strong><strong><span class="delete">下载 Zend Framework 手册</span></strong></strong></span></p>
<p><span style="text-decoration: line-through;">但是我仍然建议大家看英文手册，关于 Zend_Db 部分那个 Bug 管理的例子在最新的英文手册中已经添加了详细说明和表结构 E &#8211; R 图</span></p>
<p><span style="text-decoration: line-through;"><strong><strong><strong><span class="delete">英文 Zend Framework 手册 CHM</span></strong></strong></strong></span></p>
<p><span style="text-decoration: line-through;"><strong><strong><strong></strong></strong></strong></span></p>
<hr />好像一直没有新的版本的 chm 手册，番茄说如果有一个会比较方便，于是花了点时间编译了一下。docbook 编译的默认编码是 UTF-8，直接编译手册会造成 index 有问题。于是又写了一个小程序转换了一下编码。index部分现在是gb2312编码。 另外，不知道 Zend_Controller-QuickStart.xml 是谁翻译的，恐怕这哥们的活是白干了。全部是乱码。手册中的 controller 部分也是乱码，大家凑合。等我有时间，重新翻译了再加进来。<span style="text-decoration: line-through;"><span class="delete">下载 Zend Framework 手册</span></span></p>
<p><strong>补充：火大！火大 ！越看中文版本越火大。于是为了给自己用又编译了英文的版本。</strong> <span style="text-decoration: line-through;"><strong><span class="delete">英文 Zend Framework </span></strong><strong><span class="delete">手册 CHM</span></strong></span></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2008/07/%e7%bc%96%e8%af%91%e4%ba%86-chm-%e7%9a%84-zend-framework-%e6%89%8b%e5%86%8c/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Darby 離開了 Zend</title>
		<link>http://www.mikespook.com/2008/05/darby-%e9%9b%a2%e9%96%8b%e4%ba%86-zend/</link>
		<comments>http://www.mikespook.com/2008/05/darby-%e9%9b%a2%e9%96%8b%e4%ba%86-zend/#comments</comments>
		<pubDate>Fri, 23 May 2008 03:01:57 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[Darby]]></category>
		<category><![CDATA[離開]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/?p=129</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
5月23日對于 Zend Framework 來說絕對不是什么好日子。

首先 Darby 找到了新工作，23 日就離開了 Zend。



<span class="readmore"><a href="http://www.mikespook.com/2008/05/darby-%e9%9b%a2%e9%96%8b%e4%ba%86-zend/" title="Darby 離開了 Zend">阅读全文——共187字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>5月23日對于 Zend Framework 來說絕對不是什么好日子。</p>
<p>首先 Darby 找到了新工作，23 日就離開了 Zend。</p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/05/darby-leaving.jpg"><img class="alignnone size-medium wp-image-130" title="darby 離開 Zend" src="http://www.mikespook.com/wp-content/uploads/2008/05/darby-leaving-300x63.jpg" alt="" width="300" height="63" /></a></p>
<p><span style="text-decoration: line-through;">其次，Zend Framework 的 SVN 似乎受到毀滅性的損壞。</span></p>
<p><a href="http://www.mikespook.com/wp-content/uploads/2008/05/svn.jpg"><img class="alignnone size-medium wp-image-131" title="svn 損壞" src="http://www.mikespook.com/wp-content/uploads/2008/05/svn-300x78.jpg" alt="" width="300" height="78" /></a></p>
<p><span style="text-decoration: line-through;">本想給大家再編譯一個英文版的 Zend Framework 手冊，現在看來，只能等 SVN 恢復再說了。</span></p>
<p>最新消息，Matthew 移動了 trunk 到 standard/trunk。所以之前的 svn 無法正常使用。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2008/05/darby-%e9%9b%a2%e9%96%8b%e4%ba%86-zend/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Under the hood 的意思</title>
		<link>http://www.mikespook.com/2008/05/under-the-hood-%e7%9a%84%e6%84%8f%e6%80%9d/</link>
		<comments>http://www.mikespook.com/2008/05/under-the-hood-%e7%9a%84%e6%84%8f%e6%80%9d/#comments</comments>
		<pubDate>Thu, 22 May 2008 02:31:26 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[My life]]></category>
		<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[帽子戏法]]></category>
		<category><![CDATA[翻译]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/?p=128</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
在翻译 Zend Framework 的手册的时候遇到一个短语：Under the hood。Google 的翻译为：“在引擎盖下面”。这个意思很奇怪。hood 可以是盖子，帽子，有盖的，隐藏、蒙蔽等等意思。为什么偏偏是引擎盖呢？

上网搜了一下，居然不少专业技术翻译也推荐使用“引擎盖下面”，还有什么“魔法师的帐篷里面”（个人觉得如果是 In the hood 再这么翻译才合适）等等……

我记得中学的时候，英语老师说过，许多老外很傻，很天真。喜欢看例如从帽子里抓兔子这类低劣的魔术。那么这种魔术的一切秘密就在帽子下面——Under the hood。

<span class="readmore"><a href="http://www.mikespook.com/2008/05/under-the-hood-%e7%9a%84%e6%84%8f%e6%80%9d/" title="Under the hood 的意思">阅读全文——共357字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>在翻译 Zend Framework 的手册的时候遇到一个短语：Under the hood。Google 的翻译为：“在引擎盖下面”。这个意思很奇怪。hood 可以是盖子，帽子，有盖的，隐藏、蒙蔽等等意思。为什么偏偏是引擎盖呢？</p>
<p>上网搜了一下，居然不少专业技术翻译也推荐使用“引擎盖下面”，还有什么“魔法师的帐篷里面”（个人觉得如果是 In the hood 再这么翻译才合适）等等……</p>
<p>我记得中学的时候，英语老师说过，许多老外很傻，很天真。喜欢看例如从帽子里抓兔子这类低劣的魔术。那么这种魔术的一切秘密就在帽子下面——Under the hood。</p>
<p>所以 Under the hood 其实根据语境翻译为“本质上说”，“真正原因”，“最终的谜底” 等等都比较贴切。至于“引擎盖下面”和“魔法师的帐篷里面”还是留在汽车维修指南或者魔法入门的教材里使用吧。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2008/05/under-the-hood-%e7%9a%84%e6%84%8f%e6%80%9d/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Zend Framework 1.5 正式版 3.17 發布</title>
		<link>http://www.mikespook.com/2008/03/zend-framework-15-%e6%ad%a3%e5%bc%8f%e7%89%88-317-%e7%99%bc%e5%b8%83/</link>
		<comments>http://www.mikespook.com/2008/03/zend-framework-15-%e6%ad%a3%e5%bc%8f%e7%89%88-317-%e7%99%bc%e5%b8%83/#comments</comments>
		<pubDate>Tue, 18 Mar 2008 09:49:41 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[ninny]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/index.php/archives/104</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
今天才知道這個消息，1.5 做了很多改動，包括路由部分的大小寫解析方式也同以前 1.0x 不同。新功能對于只用 Zend Framework 開發普通網站的人來說并不是十分要緊。Zend_Form 和 Zend_Layout 反而會增加頁面編輯的難度。

* New Zend_Form component with support for AJAX-enabled form elements

* New action and view helpers for automating and facilitating AJAX requests and

<span class="readmore"><a href="http://www.mikespook.com/2008/03/zend-framework-15-%e6%ad%a3%e5%bc%8f%e7%89%88-317-%e7%99%bc%e5%b8%83/" title="Zend Framework 1.5 正式版 3.17 發布">阅读全文——共803字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>今天才知道這個消息，1.5 做了很多改動，包括路由部分的大小寫解析方式也同以前 1.0x 不同。新功能對于只用 Zend Framework 開發普通網站的人來說并不是十分要緊。Zend_Form 和 Zend_Layout 反而會增加頁面編輯的難度。</p>
<p>* New Zend_Form component with support for AJAX-enabled form elements<br />
* New action and view helpers for automating and facilitating AJAX requests and<br />
alternate response formats<br />
* LDAP, Infocard, and OpenID authentication adapters<br />
* Support for complex Lucene searches, including fuzzy, date-range, and wildcard<br />
queries<br />
* Support for Lucene 2.1 index file format<br />
* Partial, Placeholder, Action, and Header view helpers for advanced view<br />
composition and rendering<br />
* New Zend_Layout component for automating and facilitating site layouts<br />
* UTF-8 support for PDF documents</p>
<p>對于我來說修復 bug 比新功能更讓人鼓舞：</p>
<p><a href="http://framework.zend.com/issues/secure/IssueNavigator.jspa?mode=hide&amp;requestId=10661">http://framework.zend.com/issues/secure/IssueNavigator.jspa?mode=hide&amp;requestId=10661</a></p>
<p>我查了一下，我之前提交的多數 bug 都已經修復了。</p>
<p>ninny project 在實際使用中發現了很多之前設計考慮不周的地方，我準備徹底重寫。 在可能的情況下會放到 code.google.com 上去。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2008/03/zend-framework-15-%e6%ad%a3%e5%bc%8f%e7%89%88-317-%e7%99%bc%e5%b8%83/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Zend_Mail 发送邮件后提示 Fatal Error</title>
		<link>http://www.mikespook.com/2008/01/zend_mail-%e5%8f%91%e9%80%81%e9%82%ae%e4%bb%b6%e5%90%8e%e6%8f%90%e7%a4%ba-fatal-error/</link>
		<comments>http://www.mikespook.com/2008/01/zend_mail-%e5%8f%91%e9%80%81%e9%82%ae%e4%bb%b6%e5%90%8e%e6%8f%90%e7%a4%ba-fatal-error/#comments</comments>
		<pubDate>Thu, 31 Jan 2008 09:09:00 +0000</pubDate>
		<dc:creator>mikespook</dc:creator>
				<category><![CDATA[Zend Framework]]></category>

		<guid isPermaLink="false">http://www.mikespook.com/index.php/archives/80</guid>
		<description><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
这实际上是由于 PHP 不允许在析构函数中抛出异常造成的，关于这个 issue 我已经提交到 issues 上：

http://framework.zend.com/issues/browse/ZF-2534

暂时没有想到好的解决方法。通常执行到析构函数时，邮件已经正确发出。所以最不济的方法就是用try&#8230;catch&#8230; 捕获异常，并忽略掉。

<span class="readmore"><a href="http://www.mikespook.com/2008/01/zend_mail-%e5%8f%91%e9%80%81%e9%82%ae%e4%bb%b6%e5%90%8e%e6%8f%90%e7%a4%ba-fatal-error/" title="Zend_Mail 发送邮件后提示 Fatal Error">阅读全文——共342字</a></span>]]></description>
			<content:encoded><![CDATA[<style type="text/css">
#leftcontainerBox {
	float:left;
	position: fixed;
	top: 60%;
	left: 70px;
}
#leftcontainerBox .buttons {
	float:left;
	clear:both;
	margin:4px 4px 4px 4px;
	padding-bottom:2px;
}
#bottomcontainerBox {
	width: 50%;
	padding-top: 1px;
}
#bottomcontainerBox .buttons {
	float: left;
	margin: 4px 4px 4px 4px;
}
</style>
<p>这实际上是由于 PHP 不允许在析构函数中抛出异常造成的，关于这个 issue 我已经提交到 issues 上：</p>
<p><a href="http://framework.zend.com/issues/browse/ZF-2534" target="_blank">http://framework.zend.com/issues/browse/ZF-2534</a></p>
<p>暂时没有想到好的解决方法。通常执行到析构函数时，邮件已经正确发出。所以最不济的方法就是用try&#8230;catch&#8230; 捕获异常，并忽略掉。</p>
<p>如下：</p>
<p>public function __destruct()<br />
{</p>
<p><b>&nbsp;&nbsp;&nbsp;&nbsp; try<br />
</b></p>
<p><b>&nbsp;&nbsp;&nbsp; {</b><br />
&nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp;         if ($this-&gt;_connection instanceof Zend_Mail_Protocol_Smtp)</p>
<p>&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; {</p>
<p>&nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; $this-&gt;_connection-&gt;quit();</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $this-&gt;_connection-&gt;disconnect();</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }</p>
<p><b>&nbsp;&nbsp;&nbsp; catch(Zend_Exception $e)<br />
</b></p>
<p><b>&nbsp;&nbsp;&nbsp; {<br />
</b></p>
<p><b>&nbsp;&nbsp;&nbsp; }</b><br />
}</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mikespook.com/2008/01/zend_mail-%e5%8f%91%e9%80%81%e9%82%ae%e4%bb%b6%e5%90%8e%e6%8f%90%e7%a4%ba-fatal-error/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

