<?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>The old men&#039;s Weblog &#187; PHP</title>
	<atom:link href="http://webcaker.com/category/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://webcaker.com</link>
	<description>We&#039;d love to change the world, but they won&#039;t give us the source code.</description>
	<lastBuildDate>Mon, 26 Jul 2010 09:34:00 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Becareful the heredoc!</title>
		<link>http://webcaker.com/2010/02/03/becareful-the-heredoc/</link>
		<comments>http://webcaker.com/2010/02/03/becareful-the-heredoc/#comments</comments>
		<pubDate>Wed, 03 Feb 2010 10:20:54 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[heredoc]]></category>

		<guid isPermaLink="false">http://webcaker.com/?p=433</guid>
		<description><![CDATA[today , i was spent  half hour to find a bug, it said ,  Parse error: syntax error, unexpected &#8216;]&#8217;, expecting T_STRING or T_VARIABLE or T_NUM_STRING in xx line, i check that lline all words , on by  &#8230; <a href="http://webcaker.com/2010/02/03/becareful-the-heredoc/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>today , i was spent  half hour to find a bug, it said ,  Parse error: syntax error, unexpected &#8216;]&#8217;, expecting T_STRING or T_VARIABLE or T_NUM_STRING in xx line, i check that lline all words , on by one , cannot find the problem where it is , even i remove them , still has some error , check all file line by line , i found it !
because i run a function of emacs to indent line, so EOQ not in the very begin of line ! stupid me !</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2010/02/03/becareful-the-heredoc/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Simple is hard</title>
		<link>http://webcaker.com/2009/11/26/simple-is-hard/</link>
		<comments>http://webcaker.com/2009/11/26/simple-is-hard/#comments</comments>
		<pubDate>Thu, 26 Nov 2009 03:28:42 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://webcaker.com/?p=370</guid>
		<description><![CDATA[这两天看了看Rasmus（PHP作者）的一个讲座，关于Scalability、Performance 、 Security ，比较了一些PHP Framework的性能，对于Python, RoR 等语言也有一些评论，还有一些Profiling 和 Benchmarking 工具，自己需要在这一方面加强了，以前都根本没有概念，简单的一个时区的设置在php.ini里都会有影响,include_path的设置等。
Tools for PHP debug and profiling
1. apd ( Zend extension)
sudo pear install pear/apd
2. xdebug
3. apc
sudo pear install apc
extension=apc.so (added it to php.ini)
4. xdebugtoolkit
A toolkit for analyzing and visualizing xdebug cachegrind files

http://code.google.com/p/xdebugtoolkit/

5.cg2dot  &#8230; <a href="http://webcaker.com/2009/11/26/simple-is-hard/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>这两天看了看Rasmus（PHP作者）的一个讲座，关于Scalability、Performance 、 Security ，比较了一些PHP Framework的性能，对于Python, RoR 等语言也有一些评论，还有一些Profiling 和 Benchmarking 工具，自己需要在这一方面加强了，以前都根本没有概念，简单的一个时区的设置在php.ini里都会有影响,include_path的设置等。
Tools for PHP debug and profiling
1. apd ( Zend extension)
sudo pear install pear/apd
2. xdebug
3. apc
sudo pear install apc
extension=apc.so (added it to php.ini)
4. xdebugtoolkit
A toolkit for analyzing and visualizing xdebug cachegrind files

http://code.google.com/p/xdebugtoolkit/

5.cg2dot &#8211; converter from Xdebug cachegrind files to the dot format.

http://code.google.com/p/xdebugtoolkit/wiki/cg2dot


http://www.xdebug.org/docs/profiler


http://www.graphviz.org/</p>

<ol>
<li>cgsplit &#8211; splitter for appended cachegrind files.

http://code.google.com/p/xdebugtoolkit/wiki/cgsplit</li>

</ol>

<p>相关连接：</p>

<ul>
    <li><a href="http://talks.php.net/show/ntu/">Slides</a></li>
    <li><a href="http://www.flickr.com/photos/josephj/tags/ntu">Photo </a></li>
    <li><a href="http://www.flickr.com/photos/josephj/tags/ntu">http://valgrind.org</a></li>
    <li><a href="http://www.joedog.org/index/siege-home">Siege</a></li>
    <li><a href="http://sla.ckers.org/forum/list.php?3">Web application security forum</a></li>
</ul>

<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/11/26/simple-is-hard/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Back on the joomlaconsole development</title>
		<link>http://webcaker.com/2009/11/19/back-on-the-joomlaconsole-development/</link>
		<comments>http://webcaker.com/2009/11/19/back-on-the-joomlaconsole-development/#comments</comments>
		<pubDate>Thu, 19 Nov 2009 04:08:26 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[Joomla]]></category>
		<category><![CDATA[Joomla Console]]></category>

		<guid isPermaLink="false">http://webcaker.com/?p=364</guid>
		<description><![CDATA[After a short kind of vacation, i back and working on the Joomla console development, hope I can release it before the new year  (2010.1.1) .hurry up !!!
]]></description>
			<content:encoded><![CDATA[<p>After a short kind of vacation, i back and working on the <a href="http://joomlaconsole.com/" >Joomla console</a> development, hope I can release it before the new year  (2010.1.1) .hurry up !!!</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/11/19/back-on-the-joomlaconsole-development/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fixed the Joomla Plugin Error</title>
		<link>http://webcaker.com/2009/09/23/fixed-the-joomla-plugin-error/</link>
		<comments>http://webcaker.com/2009/09/23/fixed-the-joomla-plugin-error/#comments</comments>
		<pubDate>Wed, 23 Sep 2009 15:05:17 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[Joomla]]></category>
		<category><![CDATA[Joomfish]]></category>
		<category><![CDATA[Koowa]]></category>

		<guid isPermaLink="false">http://webcaker.com/?p=350</guid>
		<description><![CDATA[I have created a Joomla website with Joomfish &#38; Nook-framwork extensions, then I got a error on frontent :

Fatal error:  Class 'interceptDB' not found 
in **/plugins/system/jfdatabase/jfdatabase_inherit.php 
on line 58

why ?? because the nooku change the the getDBO of JFactory,  &#8230; <a href="http://webcaker.com/2009/09/23/fixed-the-joomla-plugin-error/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I have created a Joomla website with Joomfish &amp; Nook-framwork extensions, then I got a error on frontent :</p>

<pre xml:lang="php">Fatal error:  Class 'interceptDB' not found 
in **/plugins/system/jfdatabase/jfdatabase_inherit.php 
on line 58</pre>

<p>why ?? because the nooku change the the getDBO of JFactory, in the jfdatae_inherit.php try to include the db file based getDbo method,
so , just that based on the configuration file. solved !</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/09/23/fixed-the-joomla-plugin-error/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to override a core controller in the magento</title>
		<link>http://webcaker.com/2009/07/17/how-to-override-a-core-controller-in-the-magento/</link>
		<comments>http://webcaker.com/2009/07/17/how-to-override-a-core-controller-in-the-magento/#comments</comments>
		<pubDate>Fri, 17 Jul 2009 05:26:48 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[Controller]]></category>
		<category><![CDATA[Override]]></category>

		<guid isPermaLink="false">http://webcaker.com/?p=302</guid>
		<description><![CDATA[How to Override a core controoler in magento ?? Magento controller class override is something different then others classes. Controller override is not same as model, helper, block override. I found lot of thread on magento forum , but not  &#8230; <a href="http://webcaker.com/2009/07/17/how-to-override-a-core-controller-in-the-magento/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>How to Override a core controoler in magento ?? Magento controller class override is something different then others classes. Controller override is not same as model, helper, block override. I found lot of thread on magento forum , but not working for me (1.3.2.x),  few hours debug, I got it .so how ? a example  is override the ProductControoler ( I already create a module call Webcaker_Catalog),steps for override
Step1 : add xml config to confg.xml</p>

<pre class="brush:xml">
<config>
<frontend>
<routers>
<webcaker_catalog>
<use>standard</use>
<args>
<module>Webcaker_Catalog</module>
<frontName>catalog</frontName>
</args>
</webcaker_catalog>
</routers>

</frontend>
<global>
...
<rewrite>
  <webcaker_catalog_product>
  <from>#^/catalog/product/#</from>
    <to>/catalog/product/</to>
  </webcaker_catalog_product>
</rewrite>
</global>
</config>
</pre>

<p>Note: for from node, need use CDATA to warp it .
Step2 :
add new file ProductControler.php in the controllers in Webcaker/Catalog with code below</p>

<pre class="brush:php">
//important! Magento cannot load the ProductController automatically
require_once 'require_once 'Mage/Catalog/controllers/ProductController.php';
class Webcaker_Catalog_ProductController extends Mage_Catalog_ProductController
{
public function viewAction()
{
//your logic here
}
}
</pre>

<p>done , magento rock!</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/07/17/how-to-override-a-core-controller-in-the-magento/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>在NetBeans给magento添加提示方法功能</title>
		<link>http://webcaker.com/2009/07/12/%e5%9c%a8netbeans%e7%bb%99magento%e6%b7%bb%e5%8a%a0%e6%8f%90%e7%a4%ba%e6%96%b9%e6%b3%95%e5%8a%9f%e8%83%bd/</link>
		<comments>http://webcaker.com/2009/07/12/%e5%9c%a8netbeans%e7%bb%99magento%e6%b7%bb%e5%8a%a0%e6%8f%90%e7%a4%ba%e6%96%b9%e6%b3%95%e5%8a%9f%e8%83%bd/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 03:36:09 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[autocomplete]]></category>

		<guid isPermaLink="false">http://webcaker.com/?p=300</guid>
		<description><![CDATA[在 magento中，如果你用getModel得到一个对象时，默认没有方法提示的，可以通过添加一个注释来实现


 $quote = Mage::getModel('sales/quote')
         ->setStoreId(Mage::app()->getStore()->getId());
/* @var $quote Mage_Sales_Model_Quote */


通过var的定义，就可以有自动的方法提示了。
]]></description>
			<content:encoded><![CDATA[<p>在 magento中，如果你用getModel得到一个对象时，默认没有方法提示的，可以通过添加一个注释来实现</p>

<pre class="brush:php">
 $quote = Mage::getModel('sales/quote')
         ->setStoreId(Mage::app()->getStore()->getId());
/* @var $quote Mage_Sales_Model_Quote */
</pre>

<p>通过var的定义，就可以有自动的方法提示了。</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/07/12/%e5%9c%a8netbeans%e7%bb%99magento%e6%b7%bb%e5%8a%a0%e6%8f%90%e7%a4%ba%e6%96%b9%e6%b3%95%e5%8a%9f%e8%83%bd/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to call your hlper class in magento</title>
		<link>http://webcaker.com/2009/07/12/how-to-call-your-hlper-class-in-magento/</link>
		<comments>http://webcaker.com/2009/07/12/how-to-call-your-hlper-class-in-magento/#comments</comments>
		<pubDate>Sun, 12 Jul 2009 09:33:41 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[helper]]></category>

		<guid isPermaLink="false">http://wordpress.caker/?p=294</guid>
		<description><![CDATA[在magento中，如果你在local下面有自己的模块，并且有自己的空间（象是公司名等），如果你想引用一个 helper的时候，默认magento不能找到你的类，需要在config.xml里定义你的helper类
]]></description>
			<content:encoded><![CDATA[<p>在magento中，如果你在local下面有自己的模块，并且有自己的空间（象是公司名等），如果你想引用一个 helper的时候，默认magento不能找到你的类，需要在config.xml里定义你的helper类</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/07/12/how-to-call-your-hlper-class-in-magento/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>set cakephp to use  utf8</title>
		<link>http://webcaker.com/2009/07/12/set-cakephp-to-use-utf8/</link>
		<comments>http://webcaker.com/2009/07/12/set-cakephp-to-use-utf8/#comments</comments>
		<pubDate>Sun, 12 Jul 2009 09:31:08 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[CakePHP]]></category>
		<category><![CDATA[utf-8]]></category>

		<guid isPermaLink="false">http://wordpress.caker/?p=290</guid>
		<description><![CDATA[
    for the app ,need set the
$html-&#62;charset('utf-8') 
in your layouts file



    for database, set the encoding in the database.php in the configure folder

]]></description>
			<content:encoded><![CDATA[<ul>
    <li>for the app ,need set the
<pre><code>$html-&gt;charset('utf-8') </code></pre>
in your layouts file</li>
</ul>

<ul>
    <li>for database, set the encoding in the database.php in the configure folder</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/07/12/set-cakephp-to-use-utf8/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Class &#8216;Spyc&#8217; not found when use the Migrations in cakephp</title>
		<link>http://webcaker.com/2009/07/12/class-spyc-not-found-when-use-the-migrations-in-cakephp/</link>
		<comments>http://webcaker.com/2009/07/12/class-spyc-not-found-when-use-the-migrations-in-cakephp/#comments</comments>
		<pubDate>Sun, 12 Jul 2009 09:16:25 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[CakePHP]]></category>
		<category><![CDATA[spyc]]></category>

		<guid isPermaLink="false">http://wordpress.caker/?p=258</guid>
		<description><![CDATA[下载 了这个migrations，执行时候的时候发现提示没有找到Spyc，这里是大写的S,修改migrate.php里的vendor(‘Spyc’) 改成小写的s,修复！
]]></description>
			<content:encoded><![CDATA[<p>下载 了这个migrations，执行时候的时候发现提示没有找到<strong>Spyc</strong>，这里是大写的S,修改migrate.php里的vendor(‘Spyc’) 改成小写的s,修复！</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/07/12/class-spyc-not-found-when-use-the-migrations-in-cakephp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Undefined class &#8216;String&#8217; when use the console of cakephp</title>
		<link>http://webcaker.com/2009/07/12/undefined-class-string-when-use-the-console-of-cakephp/</link>
		<comments>http://webcaker.com/2009/07/12/undefined-class-string-when-use-the-console-of-cakephp/#comments</comments>
		<pubDate>Sun, 12 Jul 2009 09:01:25 +0000</pubDate>
		<dc:creator>caker</dc:creator>
				<category><![CDATA[CakePHP]]></category>
		<category><![CDATA[String]]></category>

		<guid isPermaLink="false">http://wordpress.caker/?p=234</guid>
		<description><![CDATA[today ,I try to learn the console of cakephp , when i ran ‘cake schema generate ‘command, i got a undefined the String class ,and i try to get answer to #cakephp on IRC.solution: adding this line :

uses('String');

at the top  &#8230; <a href="http://webcaker.com/2009/07/12/undefined-class-string-when-use-the-console-of-cakephp/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>today ,I try to learn the console of cakephp , when i ran ‘cake schema generate ‘command, i got a undefined the <code>String</code> class ,and i try to get answer to #cakephp on <span>IRC</span>.solution: adding this line :</p>

<pre><code>uses('String');</code></pre>

<p>at the top of all classes in cakelibsmodeldatasourcesdbo_source.php ,works fine!!</p>
]]></content:encoded>
			<wfw:commentRss>http://webcaker.com/2009/07/12/undefined-class-string-when-use-the-console-of-cakephp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
