<?xml version='1.0' encoding='UTF-8'?><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/" xmlns:blogger="http://schemas.google.com/blogger/2008" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" version="2.0"><channel><atom:id>tag:blogger.com,1999:blog-7142514392800287580</atom:id><lastBuildDate>Sat, 28 Sep 2024 23:16:59 +0000</lastBuildDate><category>cakephp</category><category>debug</category><category>general</category><category>javascript</category><category>model</category><category>social</category><title>dev and cakephp tips</title><description></description><link>http://codebaker.blogspot.com/</link><managingEditor>noreply@blogger.com (drex)</managingEditor><generator>Blogger</generator><openSearch:totalResults>3</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><item><guid isPermaLink="false">tag:blogger.com,1999:blog-7142514392800287580.post-3047542471927466117</guid><pubDate>Sun, 02 Dec 2007 15:03:00 +0000</pubDate><atom:updated>2007-12-03T13:21:35.179+01:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">debug</category><category domain="http://www.blogger.com/atom/ns#">javascript</category><title>Javascript debug information with firebug</title><description>Debugging javascript code can be really a pain in the ass. But if you use firebug Firefox extension you can easily output any important code directly to the console.&lt;br /&gt;&lt;br /&gt;Just type in your code:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;console.log(&#39;hello world!!!!&#39;);&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Firebug has much more great features and I cannot imagine writing javascript or ajax code without using it. Definitely this is the best firefox extension ever.</description><link>http://codebaker.blogspot.com/2007/12/javascript-debug-information-with.html</link><author>noreply@blogger.com (drex)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-7142514392800287580.post-3209841814083283692</guid><pubDate>Sun, 02 Dec 2007 13:02:00 +0000</pubDate><atom:updated>2007-12-02T14:48:09.521+01:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">cakephp</category><category domain="http://www.blogger.com/atom/ns#">model</category><title>How to setup default form values in cakephp</title><description>If you want to configure some default values for the form you can use the model&#39;s create function this way:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;//in you booking model&lt;br /&gt;function create($data) {&lt;br /&gt; if (empty($data[&#39;Booking&#39;][&#39;country_id&#39;])) {&lt;br /&gt;  $data[&#39;Booking&#39;][&#39;country_id&#39;] = 225;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; parent::create($data);&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;this would preconfigure country_id value to 255&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Update:&lt;/span&gt;&lt;br /&gt;In order to have these data available in your view you must setup $this-&gt;data variable in your controller:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$this-&gt;data = $this-&gt;Booking-&gt;create();&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;you can also setup $this-&gt;data variable directly in your controller:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$this-&gt;data[&#39;Booking&#39;][&#39;country_id&#39;];&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;* if you are testing it with firefox be aware that the browser doesn&#39;t refresh your form data values until you press ctrl+f5</description><link>http://codebaker.blogspot.com/2007/12/how-to-setup-default-form-values-in.html</link><author>noreply@blogger.com (drex)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-7142514392800287580.post-7743579201003733061</guid><pubDate>Sat, 01 Dec 2007 23:15:00 +0000</pubDate><atom:updated>2007-12-02T00:28:38.874+01:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">general</category><category domain="http://www.blogger.com/atom/ns#">social</category><title>new cake on the table</title><description>so here we are! When I found the cakephp framework a couple of months ago I was really impressed by the ease of use and multiple features it had. Very well organized, clearly defined - this is what a busy programmer needs!&lt;br /&gt;&lt;br /&gt;After all these months that have passed (and a couple of successfully implemented projects) I still discover new features that put a little smile on my face. And as I like the whole idea of sharing I created this site to put down what I find and learn.&lt;br /&gt;&lt;br /&gt;I hope you will find it useful.</description><link>http://codebaker.blogspot.com/2007/12/cake-in-kitchen.html</link><author>noreply@blogger.com (drex)</author><thr:total>0</thr:total></item></channel></rss>