<?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: Comparison of PHP frameworks &#8211; Part I</title>
	<atom:link href="http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/feed/" rel="self" type="application/rss+xml" />
	<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/</link>
	<description>No trees were killed in the production of this website.</description>
	<lastBuildDate>Sun, 28 Feb 2010 21:28:44 -0800</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Kshitij</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-446</link>
		<dc:creator>Kshitij</dc:creator>
		<pubDate>Wed, 24 Feb 2010 15:01:08 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-446</guid>
		<description>Great article buddy. I am a novice in PHP myself and am planning to go for a PHP framework and hence was confused. Was searching for exactly this and found it after a long search. But I can say the search was worth it. :)

Thanks!</description>
		<content:encoded><![CDATA[<p>Great article buddy. I am a novice in PHP myself and am planning to go for a PHP framework and hence was confused. Was searching for exactly this and found it after a long search. But I can say the search was worth it. <img src='http://daniel.carrera.bz/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Fred</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-439</link>
		<dc:creator>Fred</dc:creator>
		<pubDate>Thu, 31 Dec 2009 14:24:33 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-439</guid>
		<description>Codeigniter does provide prepared statements / binding to handle SQl injection.</description>
		<content:encoded><![CDATA[<p>Codeigniter does provide prepared statements / binding to handle SQl injection.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: adwin</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-429</link>
		<dc:creator>adwin</dc:creator>
		<pubDate>Thu, 30 Jul 2009 04:00:33 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-429</guid>
		<description>great articles to compare CI and YII ... 

I was using CI for a year and i found it really usefull . but when I look at rails I got jealously why CI has no ActiveRecord (real one .. not the one that belongs to CI at the moment)... 

so I did research and found YII ... it seems YII looks better than CI.</description>
		<content:encoded><![CDATA[<p>great articles to compare CI and YII &#8230; </p>
<p>I was using CI for a year and i found it really usefull . but when I look at rails I got jealously why CI has no ActiveRecord (real one .. not the one that belongs to CI at the moment)&#8230; </p>
<p>so I did research and found YII &#8230; it seems YII looks better than CI.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: darkredz</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-427</link>
		<dc:creator>darkredz</dc:creator>
		<pubDate>Mon, 20 Jul 2009 22:51:26 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-427</guid>
		<description>How about DooPHP? It&#039;s a high performance PHP framework and it&#039;s quite easy/flexible to learn &amp; use.</description>
		<content:encoded><![CDATA[<p>How about DooPHP? It&#8217;s a high performance PHP framework and it&#8217;s quite easy/flexible to learn &amp; use.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Raymond Steigerwalt</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-426</link>
		<dc:creator>Raymond Steigerwalt</dc:creator>
		<pubDate>Thu, 16 Jul 2009 18:37:07 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-426</guid>
		<description>I always use prepared SQL statements in Code Igniter. 

Correct me if I am wrong, but Code Igniter does support prepared statements:

$this-&gt;db-&gt;query(&quot;SELECT * FROM foo WHERE bar=?&quot;, array($baz));</description>
		<content:encoded><![CDATA[<p>I always use prepared SQL statements in Code Igniter. </p>
<p>Correct me if I am wrong, but Code Igniter does support prepared statements:</p>
<p>$this-&gt;db-&gt;query(&#8221;SELECT * FROM foo WHERE bar=?&#8221;, array($baz));</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: arun</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-425</link>
		<dc:creator>arun</dc:creator>
		<pubDate>Thu, 25 Jun 2009 14:41:10 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-425</guid>
		<description>good job ... thanks for sharing 

so I guess I should use Yii for my next project ... can you also add Symfony to the list of frameworks for comparison</description>
		<content:encoded><![CDATA[<p>good job &#8230; thanks for sharing </p>
<p>so I guess I should use Yii for my next project &#8230; can you also add Symfony to the list of frameworks for comparison</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-422</link>
		<dc:creator>Daniel</dc:creator>
		<pubDate>Tue, 16 Jun 2009 09:55:13 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-422</guid>
		<description>There is never an absolute rule. At some pointt you have to use your own judgement. But I can give you two guidelines: (1) The model should be &quot;fat&quot; and the controller &quot;thin&quot;. (2) Try to keep the separation: data stuff -&gt; model; application logic -&gt; controller.

In your specific example, I would put the things you said in the model. The idea is that the model takes care of all the nasty data mangling, many-query details, and presents your controller with a simple view of the data. This way the controller can focus on application logic. The controller gives a high-level command like &quot;create user&quot;, even if behind the scenes this might require touching several tables and some data mangling.

For your second comment: Learning new things is a good thing, and you should try to view it in a positive way. If all you know is PHP and HTML, you are very limited. That said, you don&#039;t have to use the CHtml class or any particular class in Yii. On of the things I like about Yii is very little is mandatory. Yii offers easy ways to do most things, but if Yii&#039;s solution doesn&#039;t do what you want, you are free to ignore it and do things by hand. No problem. In my own work, there are some things I do by hand rather than use Yii&#039;s methods.

I do not like Smarty. PHP itself was designed to be a templating language more than a programming language. So it seems strange that now PHP be used for programming and something else be used for templating. I find Smarty inflexible, and I don&#039;t actually want my program to deal with bad data silently. If the data is bad, I&#039;d like to find out sooner than later.

About part II: It will be a long time, I&#039;m afraid. I have a big project at work, I&#039;m getting married, and later I&#039;m going on a honey moon. So I will not have time to do part II for several months. :-(

Subscribing for comments: I am using Wordpress. If you know how to configure it so you can configure to comments, let me know. I would love to make that feature available. There must be a way. I just don&#039;t have time to go look for it. Maybe with a plugin...

Alternatively, you can just send me an email: daniel [at] carrera [d.o.t] bz

Cheers.</description>
		<content:encoded><![CDATA[<p>There is never an absolute rule. At some pointt you have to use your own judgement. But I can give you two guidelines: (1) The model should be &#8220;fat&#8221; and the controller &#8220;thin&#8221;. (2) Try to keep the separation: data stuff -&gt; model; application logic -&gt; controller.</p>
<p>In your specific example, I would put the things you said in the model. The idea is that the model takes care of all the nasty data mangling, many-query details, and presents your controller with a simple view of the data. This way the controller can focus on application logic. The controller gives a high-level command like &#8220;create user&#8221;, even if behind the scenes this might require touching several tables and some data mangling.</p>
<p>For your second comment: Learning new things is a good thing, and you should try to view it in a positive way. If all you know is PHP and HTML, you are very limited. That said, you don&#8217;t have to use the CHtml class or any particular class in Yii. On of the things I like about Yii is very little is mandatory. Yii offers easy ways to do most things, but if Yii&#8217;s solution doesn&#8217;t do what you want, you are free to ignore it and do things by hand. No problem. In my own work, there are some things I do by hand rather than use Yii&#8217;s methods.</p>
<p>I do not like Smarty. PHP itself was designed to be a templating language more than a programming language. So it seems strange that now PHP be used for programming and something else be used for templating. I find Smarty inflexible, and I don&#8217;t actually want my program to deal with bad data silently. If the data is bad, I&#8217;d like to find out sooner than later.</p>
<p>About part II: It will be a long time, I&#8217;m afraid. I have a big project at work, I&#8217;m getting married, and later I&#8217;m going on a honey moon. So I will not have time to do part II for several months. <img src='http://daniel.carrera.bz/wp-includes/images/smilies/icon_sad.gif' alt=':-(' class='wp-smiley' /> </p>
<p>Subscribing for comments: I am using Wordpress. If you know how to configure it so you can configure to comments, let me know. I would love to make that feature available. There must be a way. I just don&#8217;t have time to go look for it. Maybe with a plugin&#8230;</p>
<p>Alternatively, you can just send me an email: daniel [at] carrera [d.o.t] bz</p>
<p>Cheers.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Janis</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-421</link>
		<dc:creator>Janis</dc:creator>
		<pubDate>Mon, 15 Jun 2009 18:56:17 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-421</guid>
		<description>Thanks for the brief explanation. In general, I somewhat know what those three are but in practice I got confused. For example, if there is some chunk of code that does extended input data processing prior to saving it, or does some extensive data calculation along with decisions on what kind of data select from the DB (may be with several different queries) before displaying it - where this code should go? Directly in the controller&#039;s method who&#039;s responsible for a particular page, in a subfunction or in some component, or maybe some model should deal with all that? And when should the properties of a controller be used and when they should be passed to the view with render function?

Another problem I have with Yii is that I need to learn many news things which I would know how to do in plain PHP or HTML, but which are supposed to be done by the countless Yii&#039;s built-in helper classes and functions. For example, the form labels and input fields are generated by some CHtml methods. And even when I&#039;ve found what parameters must be passed, it can turn out that it does not fit my needs, for example, the generation of label does not allow a colon be added after the label itself.

Also I like Smarty very much (it offers an easier to use mark-up than PHP and deals with all the undefined variables silently), and Yii doesn&#039;t support it. :(

A thing I like about it is that it supports several internalization techniques, in particular it supports GNU Gettext (po/mo files) which I decided to use and which, as I see, are not supported by Kohana. :(

Well, anyway, I&#039;m looking forward to your comparison part II. Isn&#039;t there a way to subscribe to comments here, as I won&#039;t remember to come back otherwise.</description>
		<content:encoded><![CDATA[<p>Thanks for the brief explanation. In general, I somewhat know what those three are but in practice I got confused. For example, if there is some chunk of code that does extended input data processing prior to saving it, or does some extensive data calculation along with decisions on what kind of data select from the DB (may be with several different queries) before displaying it &#8211; where this code should go? Directly in the controller&#8217;s method who&#8217;s responsible for a particular page, in a subfunction or in some component, or maybe some model should deal with all that? And when should the properties of a controller be used and when they should be passed to the view with render function?</p>
<p>Another problem I have with Yii is that I need to learn many news things which I would know how to do in plain PHP or HTML, but which are supposed to be done by the countless Yii&#8217;s built-in helper classes and functions. For example, the form labels and input fields are generated by some CHtml methods. And even when I&#8217;ve found what parameters must be passed, it can turn out that it does not fit my needs, for example, the generation of label does not allow a colon be added after the label itself.</p>
<p>Also I like Smarty very much (it offers an easier to use mark-up than PHP and deals with all the undefined variables silently), and Yii doesn&#8217;t support it. <img src='http://daniel.carrera.bz/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>
<p>A thing I like about it is that it supports several internalization techniques, in particular it supports GNU Gettext (po/mo files) which I decided to use and which, as I see, are not supported by Kohana. <img src='http://daniel.carrera.bz/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>
<p>Well, anyway, I&#8217;m looking forward to your comparison part II. Isn&#8217;t there a way to subscribe to comments here, as I won&#8217;t remember to come back otherwise.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-420</link>
		<dc:creator>Daniel</dc:creator>
		<pubDate>Mon, 15 Jun 2009 15:08:00 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-420</guid>
		<description>Hi Janis,

I didn&#039;t know much about MVC when I started using Yii. Certainly not more than what you would get on a Wikipedia article.

In brief, the Model means your data. That is, the database and the methods that talk to the database directly (create, read, update and delete records). The View is the user interface. It&#039;s the HTML, the menus, links, etc. The Controller is the layer in between. The Controller is the brains of the application. This is where the application logic lives. The Controller tells the Model to fetch some data, and chooses the correct view to display that data.

Hope that helps.</description>
		<content:encoded><![CDATA[<p>Hi Janis,</p>
<p>I didn&#8217;t know much about MVC when I started using Yii. Certainly not more than what you would get on a Wikipedia article.</p>
<p>In brief, the Model means your data. That is, the database and the methods that talk to the database directly (create, read, update and delete records). The View is the user interface. It&#8217;s the HTML, the menus, links, etc. The Controller is the layer in between. The Controller is the brains of the application. This is where the application logic lives. The Controller tells the Model to fetch some data, and chooses the correct view to display that data.</p>
<p>Hope that helps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Janis</title>
		<link>http://daniel.carrera.bz/2009/01/comparison-of-php-frameworks-part-i/comment-page-1/#comment-419</link>
		<dc:creator>Janis</dc:creator>
		<pubDate>Mon, 15 Jun 2009 08:53:23 +0000</pubDate>
		<guid isPermaLink="false">http://daniel.carrera.name/?p=191#comment-419</guid>
		<description>Very useful comparison. I hope you&#039;ll get around to making part II, too.

I&#039;m currently trying Yii myself, but after this post I may take a look at CodeIgnite or Kohana, too. Yii may have a good documentation for people who are not new with MVC and frameworks, but for me there is too little explanation of what is what. Too many &quot;explanations&quot; looks like &quot;a controller is an instance of CController or its child class&quot; - which actually doesn&#039;t tell anything about what it really is.</description>
		<content:encoded><![CDATA[<p>Very useful comparison. I hope you&#8217;ll get around to making part II, too.</p>
<p>I&#8217;m currently trying Yii myself, but after this post I may take a look at CodeIgnite or Kohana, too. Yii may have a good documentation for people who are not new with MVC and frameworks, but for me there is too little explanation of what is what. Too many &#8220;explanations&#8221; looks like &#8220;a controller is an instance of CController or its child class&#8221; &#8211; which actually doesn&#8217;t tell anything about what it really is.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
