<?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>cObaia.net &#187; programação</title>
	<atom:link href="http://cobaia.net/categorias/programacao/feed/" rel="self" type="application/rss+xml" />
	<link>http://cobaia.net</link>
	<description>CakePHP, PHP por Vinícius Krolow</description>
	<lastBuildDate>Wed, 01 Sep 2010 20:25:12 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1-alpha</generator>
		<item>
		<title>MySQL, Multiple select in the same table with the result together and order condition applied on all result</title>
		<link>http://cobaia.net/2010/08/mysql-multiple-select-in-the-same-table-with-the-result-together-and-order-condition-applied-on-all-result/</link>
		<comments>http://cobaia.net/2010/08/mysql-multiple-select-in-the-same-table-with-the-result-together-and-order-condition-applied-on-all-result/#comments</comments>
		<pubDate>Thu, 12 Aug 2010 13:31:32 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[programação]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=654</guid>
		<description><![CDATA[Today I needed made a multiple select, more than one SELECT command in the same table, but the result should comes together and I also needed apply one condition for ORDER in all result. Firstly I tried read if CakePHP has supports for it, but CakePHP doesn&#8217;t has, so I pass to try a MySQL [...]]]></description>
			<content:encoded><![CDATA[<p>Today I needed made a multiple select, more than one SELECT command in the same table, but the result should comes together and I also needed apply one condition for ORDER in all result.</p>
<p>Firstly I tried read if CakePHP has supports for it, but CakePHP doesn&#8217;t has, so I pass to try a MySQL query solution for that, and that solution is the command <a href="http://dev.mysql.com/doc/refman/5.0/en/union.html">UNION</a>.</p>
<p>For example:</p>
<p>Table <strong>people</strong></p>
<p><strong>id<br />
name<br />
</strong><strong>age </strong></p>
<p><strong><span style="font-weight: normal;">If for example we want show <strong>30 person with age equal 2</strong>0 and more </span>20 with the age equal 10.</strong></p>
<p>With the union condition this is simple.</p>

<div class="wp_codebox"><table><tr id="p6544"><td class="line_numbers"><pre>1
2
3
</pre></td><td class="code" id="p654code4"><pre class="sql" style="font-family:monospace;"><span style="color: #66cc66;">&#40;</span><span style="color: #993333; font-weight: bold;">SELECT</span> <span style="color: #66cc66;">*</span> <span style="color: #993333; font-weight: bold;">FROM</span> people <span style="color: #993333; font-weight: bold;">WHERE</span> age<span style="color: #66cc66;">=</span><span style="color: #cc66cc;">20</span> <span style="color: #993333; font-weight: bold;">LIMIT</span> <span style="color: #cc66cc;">30</span><span style="color: #66cc66;">&#41;</span>
<span style="color: #993333; font-weight: bold;">UNION</span>
<span style="color: #66cc66;">&#40;</span><span style="color: #993333; font-weight: bold;">SELECT</span> <span style="color: #66cc66;">*</span> <span style="color: #993333; font-weight: bold;">FROM</span> people <span style="color: #993333; font-weight: bold;">WHERE</span> age<span style="color: #66cc66;">=</span><span style="color: #cc66cc;">10</span> <span style="color: #993333; font-weight: bold;">LIMIT</span> <span style="color: #cc66cc;">20</span><span style="color: #66cc66;">&#41;</span>;</pre></td></tr></table></div>

<p>So how you can check, it&#8217;s  pretty simple, make your two queries and apply the command UNION, if you want to apply one order or another thing in the result you should put it in the end</p>

<div class="wp_codebox"><table><tr id="p6545"><td class="line_numbers"><pre>1
2
3
4
</pre></td><td class="code" id="p654code5"><pre class="sql" style="font-family:monospace;"><span style="color: #66cc66;">&#40;</span><span style="color: #993333; font-weight: bold;">SELECT</span> <span style="color: #66cc66;">*</span> <span style="color: #993333; font-weight: bold;">FROM</span> people <span style="color: #993333; font-weight: bold;">WHERE</span> age<span style="color: #66cc66;">=</span><span style="color: #cc66cc;">20</span> <span style="color: #993333; font-weight: bold;">LIMIT</span> <span style="color: #cc66cc;">30</span><span style="color: #66cc66;">&#41;</span>
<span style="color: #993333; font-weight: bold;">UNION</span>
<span style="color: #66cc66;">&#40;</span><span style="color: #993333; font-weight: bold;">SELECT</span> <span style="color: #66cc66;">*</span> <span style="color: #993333; font-weight: bold;">FROM</span> people <span style="color: #993333; font-weight: bold;">WHERE</span> age<span style="color: #66cc66;">=</span><span style="color: #cc66cc;">10</span> <span style="color: #993333; font-weight: bold;">LIMIT</span> <span style="color: #cc66cc;">20</span><span style="color: #66cc66;">&#41;</span>
<span style="color: #993333; font-weight: bold;">ORDER</span> <span style="color: #993333; font-weight: bold;">BY</span> name <span style="color: #993333; font-weight: bold;">ASC</span>;</pre></td></tr></table></div>

<p>Worth remembering, the fields that result will come should be equal, this in the case that you are not using the same table, but two tables distinct with different fields between these.</p>
<p>In the case of CakePHP framework, apply the query method of your model for example:</p>

<div class="wp_codebox"><table><tr id="p6546"><td class="line_numbers"><pre>1
2
3
4
5
</pre></td><td class="code" id="p654code6"><pre class="php" style="font-family:monospace;"><span style="color: #000088;">$nodes</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Node</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">query</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'
(SELECT Node.* FROM nodes AS Node WHERE type=3 ORDER BY date DESC LIMIT 30)
UNION
(SELECT Node.* FROM nodes AS Node WHERE type!=3 ORDER BY date DESC LIMIT 200) 
ORDER BY date DESC;'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2010/08/mysql-multiple-select-in-the-same-table-with-the-result-together-and-order-condition-applied-on-all-result/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Xavante na WEB, Experimento em HTML5, CSS3, jQuery e CakePHP com Crawler usando phpQuery</title>
		<link>http://cobaia.net/2010/08/xavante-na-web-experimento-em-html5-css3-jquery-e-cakephp-com-crawler-usando-phpquery/</link>
		<comments>http://cobaia.net/2010/08/xavante-na-web-experimento-em-html5-css3-jquery-e-cakephp-com-crawler-usando-phpquery/#comments</comments>
		<pubDate>Tue, 10 Aug 2010 01:56:32 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=650</guid>
		<description><![CDATA[Hoje postei no ar um experimento(projeto) o Xavante na Web, para testar algumas tecnologias são elas HTML5, CSS3, Jquery e o phpQuery, junto com a integração de algumas API&#8217;s, hoje 09.08 de agosto a do twitter já está no ar, e a do Flickr e Youtube, virão em seguida visto que as duas já foram [...]]]></description>
			<content:encoded><![CDATA[<p>Hoje postei no ar um <a href="http://xavante.cobaia.net">experimento(projeto)</a> o Xavante na Web, para testar algumas tecnologias são elas HTML5, CSS3, <a href="http://jquery.com">Jquery</a> e o <a href="http://code.google.com/p/phpquery/">phpQuery</a>, junto com a integração de algumas API&#8217;s, hoje 09.08 de agosto a do twitter já está no ar, e a do Flickr e Youtube, virão em seguida visto que as duas já foram codificadas bastando o cacheamento das mesmas.</p>
<p>Para o mesmo foi gasto 3 horas de desenvolvimento, mais 1 hora de acertos que com sua publicação ficou beirando as 5 horas, usando P<a href="http://php.net">HP 5.2</a>, <a href="http://mysql.org">MySQL 5</a> e <a href="http://cakephp.org">CakePHP 1.3</a>.</p>
<p>O <a href="http://xavante.cobaia.net">Xavante na Web</a>, nada mais é que um agregador de notícias, assuntos, imagens vídeos relacionados ao Grêmio Esportivo Brasil, meu time de coração!</p>
<p>Pretendo nele ir aplicando novas técnicas, e por em prática HTML5 e CSS3 que venho estudando, para o mesmo criei uma Classe PHP para fazer a parte de <a href="http://pt.wikipedia.org/wiki/Web_crawler">Crawler</a>, que após eu ter uma suite de teste dela pretendo publicar por aqui, por hora é isso.</p>
]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2010/08/xavante-na-web-experimento-em-html5-css3-jquery-e-cakephp-com-crawler-usando-phpquery/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CakePHP adicionando Paths de Controllers, Models, Helpers, Components, Views, Plugins, Locales e Shell.</title>
		<link>http://cobaia.net/2009/08/cakephp-adicionando-paths-de-controllers-models-helpers-components-views-plugins-locales-e-shell/</link>
		<comments>http://cobaia.net/2009/08/cakephp-adicionando-paths-de-controllers-models-helpers-components-views-plugins-locales-e-shell/#comments</comments>
		<pubDate>Thu, 06 Aug 2009 13:42:52 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=593</guid>
		<description><![CDATA[Uma funcionalidade legal do CakePHP é a possibilidade de adicionar novos PATHS (caminho de diretórios) que contenham código fonte, com isso por exemplo é possível criar um diretório onde podemos fazer compartilhamento de plugins com diversos projetos. Todos esses Paths você pode definir no bootstrap de sua aplicação esse se encontra em: config/bootstrap.php 1 2 [...]]]></description>
			<content:encoded><![CDATA[<p>Uma funcionalidade legal do <a href="http://cakephp.org">CakePHP</a> é a possibilidade de adicionar novos PATHS (caminho de diretórios) que contenham código fonte, com isso por exemplo é possível criar um diretório onde podemos fazer compartilhamento de plugins com diversos projetos.</p>
<p>Todos esses Paths você pode definir no bootstrap de sua aplicação esse se encontra em: <code>config/bootstrap.php</code></p>

<div class="wp_codebox"><table><tr id="p5938"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
</pre></td><td class="code" id="p593code8"><pre class="php" style="font-family:monospace;">	<span style="color: #000088;">$controllerPaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$viewPaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$modelPaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$helperPaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$componentPaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$pluginPaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$vendorPaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$localePaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$shellPaths</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<p>Pode ser passados vários PATHS no <code>array</code>, e todos serão adicionados junto com os PATHS padrões do CakePHP 1.2.</p>
<p>Além da funcionalidade de compartilhar código, pode se fazer algumas especializações com esse tipo de funcionalidade, com criatividade e lógica é possível criar controllers com mesmo nome e dependendo da situação um dos dois serem chamados, assim como fazer overwrite das classes de modelo, etc&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2009/08/cakephp-adicionando-paths-de-controllers-models-helpers-components-views-plugins-locales-e-shell/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Novas versões do CakePHP, CakePHP 1.2, CakePHP 2 e Cake 3</title>
		<link>http://cobaia.net/2009/08/novas-versoes-do-cakephp-cakephp-1-2-cakephp-2-e-cake-3/</link>
		<comments>http://cobaia.net/2009/08/novas-versoes-do-cakephp-cakephp-1-2-cakephp-2-e-cake-3/#comments</comments>
		<pubDate>Thu, 06 Aug 2009 02:07:09 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[frameworks]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=587</guid>
		<description><![CDATA[Foi lançada duas novas versões do CakePHP, um novo released da versão 1.2 (CakePHP 1.2) e uma versão de desenvolvimento do Cake 3. Curiosidade da versão do Cake 3 é a mudança de nome que provavelmente foi dada por causa da licensa do &#8220;PHP&#8221;. 3. The name "PHP" must not be used to endorse or [...]]]></description>
			<content:encoded><![CDATA[<p>Foi lançada duas novas versões do CakePHP, um novo released da versão 1.2 (CakePHP 1.2) e uma versão de desenvolvimento do Cake 3.</p>
<p>Curiosidade da versão do Cake 3 é a mudança de nome que provavelmente foi dada por causa da licensa do &#8220;PHP&#8221;.</p>
<pre>  3. The name "PHP" must not be used to endorse or promote products
     derived from this software without prior written permission. For
     written permission, please contact group@php.net.</pre>
<p>Veja toda a Licensa do <a href="http://www.php.net/license/3_01.txt">PHP aqui</a>.</p>
<p>Ou seja só pode usar o nome PHP em algum produto com autorização do PHP, não sei se as outras versões possuem essa autorização mas todavia, acho que o Cake está encaminhando a mudar o nome.</p>
<p>O released CakePHP 1.2.4.8284, é de bug fixes, com pequenas mudanças, e alguns bugs fixed, assim como melhorias nos tests. Todas as mudanças na versão do CakePHP 1.2 pode ser visto no <a href="https://trac.cakephp.org/wiki/changelog/1.2.x.x/8284">changelog</a>.</p>
<p>Enquanto a versão <a href="http://code.cakephp.org/cake3">Cake 3</a>, está sendo desenvolvida utilizando os recursos do PHP 5.3, como funções anonimas e namespace, que irão ajudar muito principalmente no desenvolvimento de plugins que será muito mais fácil, pois será agora possível a criação de pacotes. Assim como o conflito com o nome de classes que não irão correr mais, e isso é um grande ponto.</p>
<p>A versão Cake3 será totalmente reformulada e vale a pena acompanhar o <a href="http://code.cakephp.org/cake3">repositório</a> o que está por vir.</p>
<p>Em paralelo está sendo desenvolvido o <a href="http://code.cakephp.org/cakephp2">CakePHP 2</a>, que será um refactoring do código do CakePHP 1.2 para PHP 5 para rodar em strict com o PHP 5.</p>
]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2009/08/novas-versoes-do-cakephp-cakephp-1-2-cakephp-2-e-cake-3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CakePHP 1.2 problemas de Encode UTF-8 ISO-8859-1</title>
		<link>http://cobaia.net/2009/08/cakephp-1-2-problemas-de-encode-utf-8-iso-8859-1/</link>
		<comments>http://cobaia.net/2009/08/cakephp-1-2-problemas-de-encode-utf-8-iso-8859-1/#comments</comments>
		<pubDate>Wed, 05 Aug 2009 14:59:03 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[frameworks]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=584</guid>
		<description><![CDATA[Seguido várias pessoas tem problemas com encode no desenvolvimento com CakePHP 1.2, são pequenos erros que levam a fazer isso, para solucionar os mesmos normalmente é simples, porém vou buscar descrever aqui onde a maioria pode ocorrer: Database Config No config/database.php, onde definimos a conexão a base de dados do CakePHP, é possível definir nomes [...]]]></description>
			<content:encoded><![CDATA[<p>Seguido várias pessoas tem problemas com encode no desenvolvimento com CakePHP 1.2, são pequenos erros que levam a fazer isso, para solucionar os mesmos normalmente é simples, porém vou buscar descrever aqui onde a maioria pode ocorrer:</p>
<h3>Database Config</h3>
<p>No <code>config/database.php</code>, onde definimos a conexão a base de dados do CakePHP, é possível definir nomes de atributos que serão os nomes do tipo de conexão a base de dados.</p>
<p>Exemplo:</p>

<div class="wp_codebox"><table><tr id="p58412"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
</pre></td><td class="code" id="p584code12"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&lt;</span> ?php
<span style="color: #000000; font-weight: bold;">class</span> DATABASE_CONFIG <span style="color: #009900;">&#123;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">var</span> <span style="color: #000088;">$default</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span>
		<span style="color: #0000ff;">'driver'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'mysql'</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'persistent'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'host'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'localhost'</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'login'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'root'</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'password'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'root'</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'database'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'abccc'</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'encoding'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'utf8'</span><span style="color: #339933;">,</span>
	<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>O importante aqui é definir o hash enconding no array do attributo da sua configuração de banco, no caso foi definido utf8 (sem o hífen).</p>
<h3>Aplicação Charset</h3>
<p>No arquivo <code>config/core.php</code>, existe a configuração de encoding a ser definida para aplicação:</p>

<div class="wp_codebox"><table><tr id="p58413"><td class="line_numbers"><pre>1
2
3
4
</pre></td><td class="code" id="p584code13"><pre class="php" style="font-family:monospace;"><span style="color: #009933; font-style: italic;">/**
 * Application wide charset encoding
 */</span>
	Configure<span style="color: #339933;">::</span><span style="color: #004000;">write</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'App.encoding'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'UTF-8'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<p>Sete nela o mesmo encode que você está usando ao longo da aplicação.</p>
<h3>Charset do HTML</h3>
<p>Outro local que definimos o encode da aplicação agora no caso o encode do HTML, é no helper Html, no layout verificar o:</p>

<div class="wp_codebox"><table><tr id="p58414"><td class="line_numbers"><pre>1
</pre></td><td class="code" id="p584code14"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&lt;</span> ?php <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$html</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">charset</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>Por padrão o arquivo <code>views/layouts/default.ctp</code> já contei a impressão do meta charset, e não é necessário passar parâmetro para o mesmo, visto que já foi definido no <code>config/core.php</code> o encoding default da aplicação, logo o HtmlHelper pega o que foi definido no <code>config/core.php</code>. </p>
<p>Se o seu arquivo de layout não contem a sua adição pode ser necessária.</p>
<h3>Database</h3>
<p>Por último se continuar ainda com problemas de encoding, é necessário verificar seu banco de dados criado, verifique se o mesmo está setado com o encode esperado, assim como as tabelas e os atributos do tipo string estão também usando o mesmo encode.</p>
<h3>Files</h3>
<p>Outra verificação a ser feita é o encode dos arquivos, vale lembrar que os arquivos PHP devem estar no mesmo encode do resto da aplicação, para verificar isso no linux você pode usar o comando file: <code>file arquivo.php</code>, ele irá enformar o encode do arquivo, caso esteja errado converta o arquivo para o encode correto.</p>
<p>Esses processos são triviais ao longo do desenvolvimento com o CakePHP, e para aqueles que estão com algum problema provavelmente, algum desses processos descritos devem estar levando a sua aplicação CakePHP a apresentar esse tipo de error.</p>
]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2009/08/cakephp-1-2-problemas-de-encode-utf-8-iso-8859-1/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Facilitar a configuração de projetos PHP</title>
		<link>http://cobaia.net/2009/07/facilitar-a-configuracao-de-projetos-php/</link>
		<comments>http://cobaia.net/2009/07/facilitar-a-configuracao-de-projetos-php/#comments</comments>
		<pubDate>Thu, 30 Jul 2009 17:08:26 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=580</guid>
		<description><![CDATA[Resolvi criar um simples script para facilitar a configuração de projetos PHP, a cada vez que eu ia começar 1, era necessário eu criar um novo virtual host, adicionar no hosts o alias do ip, restartar apache, etc&#8230; Então fiz um script simples, realmente simples em PHP para executar por linha de comando PHP-CLI, vou [...]]]></description>
			<content:encoded><![CDATA[<p>Resolvi criar um simples script para facilitar a configuração de projetos PHP, a cada vez que eu ia começar 1, era necessário eu criar um novo virtual host, adicionar no hosts o alias do ip, restartar apache, etc&#8230;</p>
<p>Então fiz um script simples, realmente simples em PHP para executar por linha de comando PHP-CLI, vou deixar a disposição para alguém que queria:</p>
<p>create-project.php</p>

<div class="wp_codebox"><table><tr id="p58016"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
</pre></td><td class="code" id="p580code16"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&lt;</span> ?php
&nbsp;
	<span style="color: #666666; font-style: italic;">/*
	 * Template of virtual host
	 */</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&lt;VirtualHost *:80&gt;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;ServerName <span style="color: #006699; font-weight: bold;">{$argv[1]}</span><span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;DocumentRoot <span style="color: #006699; font-weight: bold;">{$argv[2]}</span><span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;&lt;directory <span style="color: #006699; font-weight: bold;">{$argv[2]}</span>&gt;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;	Options Indexes FollowSymLinks MultiViews<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;	AllowOverride All<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$tempalte</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;	Order allow,deny<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;	allow from all<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;&lt;/directory&gt;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
    	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;ErrorLog /var/log/apache2/<span style="color: #006699; font-weight: bold;">{$argv[1]}</span>_error.log<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;   LogLevel warn<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;    CustomLog /var/log/apache2/<span style="color: #006699; font-weight: bold;">{$argv[1]}</span>_access.log combined<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>        
	<span style="color: #000088;">$template</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #b1b100;">echo</span> <span style="color: #000088;">$template</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$file</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/fopen"><span style="color: #990000;">fopen</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;/etc/apache2/sites-available/<span style="color: #006699; font-weight: bold;">{$argv[1]}</span>&quot;</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'x'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<a href="http://www.php.net/fwrite"><span style="color: #990000;">fwrite</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #339933;">,</span> <span style="color: #000088;">$template</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<a href="http://www.php.net/fclose"><span style="color: #990000;">fclose</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<a href="http://www.php.net/exec"><span style="color: #990000;">exec</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ln -s /etc/apache2/sites-available/<span style="color: #006699; font-weight: bold;">{$argv[1]}</span> /etc/apache2/sites-enabled/<span style="color: #006699; font-weight: bold;">{$argv[1]}</span>&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$file</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/fopen"><span style="color: #990000;">fopen</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;/etc/hosts&quot;</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'a+'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<a href="http://www.php.net/fwrite"><span style="color: #990000;">fwrite</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">&quot;127.0.0.1 <span style="color: #006699; font-weight: bold;">{$argv[1]}</span><span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<a href="http://www.php.net/fclose"><span style="color: #990000;">fclose</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<a href="http://www.php.net/exec"><span style="color: #990000;">exec</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'/etc/init.d/apache2 restart'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'Created with success the config for: '</span><span style="color: #339933;">,</span> <span style="color: #000088;">$argv</span><span style="color: #009900;">&#91;</span><span style="color: #cc66cc;">1</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span> 
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>Para usar basta executar como root:</p>
<pre>
sudo php create-project.php nome_projeto /var/diretorio/
</pre>
<p>E pronto, ele criara o vhost, insere no hosts o alias, aponta o vhost para o diretório indicado e restarta o apache.</p>
<p>Ele funciona no Ubuntu linux, não testei em outras distros, e provavelmente possa não funcionar.</p>
]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2009/07/facilitar-a-configuracao-de-projetos-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CakePHP 1.2 Validação de formulários sem Modelos</title>
		<link>http://cobaia.net/2009/07/cakephp-1-2-validacao-de-formularios-sem-modelos/</link>
		<comments>http://cobaia.net/2009/07/cakephp-1-2-validacao-de-formularios-sem-modelos/#comments</comments>
		<pubDate>Tue, 21 Jul 2009 22:12:23 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=576</guid>
		<description><![CDATA[No CakePHP, as regras de definições são definidas nos modelos, então como fazemos quando queremos gerar um formulário, porém esse formulário não necessariamente vai ser salvo em um banco de dados, logo não tem modelo. Para fazer isso na verdade criamos um modelo, esse modelo usamos como citado no post anterior. Ou seja, um modelo [...]]]></description>
			<content:encoded><![CDATA[<p>No CakePHP, as regras de definições são definidas nos modelos, então como fazemos quando queremos gerar um formulário, porém esse formulário não necessariamente vai ser salvo em um banco de dados, logo não tem modelo.</p>
<p>Para fazer isso na verdade criamos um modelo, esse modelo usamos como citado no <a href="http://cobaia.net/2009/07/cakephp-model-sem-tabela/">post anterior</a>. Ou seja, um modelo sem tabela.</p>
<p>Vamos por em prática com um caso de um formulário de contato:</p>
<h3>Criando o modelo, sem tabela no CakePHP</h3>
<p>file contact.php</p>

<div class="wp_codebox"><table><tr id="p57620"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
</pre></td><td class="code" id="p576code20"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&lt;</span> ?php
<span style="color: #000000; font-weight: bold;">class</span> Contact <span style="color: #000000; font-weight: bold;">extends</span> AppModel <span style="color: #009900;">&#123;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000088;">$useTable</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span>
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000088;">$validate</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span>
		<span style="color: #0000ff;">'name'</span> <span style="color: #339933;">=&gt;</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'rule'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'notEmpty'</span><span style="color: #339933;">,</span> 
						<span style="color: #0000ff;">'message'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">&quot;Can't be empty the field name&quot;</span><span style="color: #339933;">,</span>
						<span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'email'</span> <span style="color: #339933;">=&gt;</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'rule'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'email'</span><span style="color: #339933;">,</span>
						 <span style="color: #0000ff;">'message'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">&quot;Put a email valid&quot;</span><span style="color: #339933;">,</span>
						<span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'message'</span> <span style="color: #339933;">=&gt;</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'rule'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'notEmpty'</span><span style="color: #339933;">,</span> 
						<span style="color: #0000ff;">'message'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">&quot;Can't be empty the field message&quot;</span><span style="color: #339933;">,</span>
						<span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span>
	<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>Definidos três campos a serem validados, name, email e message.</p>
<p>Agora na view:</p>

<div class="wp_codebox"><table><tr id="p57621"><td class="line_numbers"><pre>1
2
3
4
5
6
7
</pre></td><td class="code" id="p576code21"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&lt;</span> ?php <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$form</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">create</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Contact'</span><span style="color: #339933;">,</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'url'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'/contact/'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
	<span style="color: #339933;">&lt;</span>fieldset<span style="color: #339933;">&gt;</span>
		<span style="color: #339933;">&lt;</span> ?php <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$form</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">input</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'name'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
		<span style="color: #339933;">&lt;</span> ?php <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$form</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">input</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'email'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
		<span style="color: #339933;">&lt;</span> ?php <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$form</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">input</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'message'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
	<span style="color: #339933;">&lt;/</span>fieldset<span style="color: #339933;">&gt;</span>
<span style="color: #339933;">&lt;</span> ?php <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$form</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">end</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Send'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>Criamos o form usando nosso modelo, onde guardamos a regra de validação, e mandamos imprimir os campos.</p>
<p>No controller:</p>

<div class="wp_codebox"><table><tr id="p57622"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
</pre></td><td class="code" id="p576code22"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&lt;</span> ?php
<span style="color: #000000; font-weight: bold;">class</span> ContactController <span style="color: #000000; font-weight: bold;">extends</span> AppController <span style="color: #009900;">&#123;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000088;">$name</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'Contact'</span><span style="color: #339933;">;</span>
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000088;">$uses</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Contact'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> index<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><a href="http://www.php.net/empty"><span style="color: #990000;">empty</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">data</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Contact</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">set</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">data</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
			<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Contact</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">validates</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
				<span style="color: #666666; font-style: italic;">//send mail</span>
			<span style="color: #009900;">&#125;</span>
		<span style="color: #009900;">&#125;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>Pronto usamos o modelo para validar os campos de formulário antes de fazermos nosso envio do email de contato.</p>
]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2009/07/cakephp-1-2-validacao-de-formularios-sem-modelos/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>CakePHP Model sem Tabela</title>
		<link>http://cobaia.net/2009/07/cakephp-model-sem-tabela/</link>
		<comments>http://cobaia.net/2009/07/cakephp-model-sem-tabela/#comments</comments>
		<pubDate>Tue, 21 Jul 2009 14:06:09 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[frameworks]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=574</guid>
		<description><![CDATA[Algumas vezes precisamos de modelos sem tabela do banco de dados, e para fazer isso no CakePHP, temos um attributo que definimos o uso ou não de tabelas no modelo: 1 2 3 4 5 6 7 &#60; ?php class User extends AppModel &#123; &#160; public $useTable = false; &#160; &#125; ?&#62;]]></description>
			<content:encoded><![CDATA[<p>Algumas vezes precisamos de modelos sem tabela do banco de dados, e para fazer isso no CakePHP, temos um attributo que definimos o uso ou não de tabelas no modelo:</p>

<div class="wp_codebox"><table><tr id="p57424"><td class="line_numbers"><pre>1
2
3
4
5
6
7
</pre></td><td class="code" id="p574code24"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&lt;</span> ?php
<span style="color: #000000; font-weight: bold;">class</span> User <span style="color: #000000; font-weight: bold;">extends</span> AppModel <span style="color: #009900;">&#123;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000088;">$useTable</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2009/07/cakephp-model-sem-tabela/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Download apresentações do CakeFest3 &#8211; Berlin 2009</title>
		<link>http://cobaia.net/2009/07/download-apresentacoes-do-cakefest3-berlin-2009/</link>
		<comments>http://cobaia.net/2009/07/download-apresentacoes-do-cakefest3-berlin-2009/#comments</comments>
		<pubDate>Wed, 15 Jul 2009 14:46:11 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[cakephp]]></category>
		<category><![CDATA[frameworks]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=572</guid>
		<description><![CDATA[Ocorreu nesse mês em Berlin o CakeFest3, para as pessoas como eu, que não puderam se fazer presente no evento, vale a pena da uma olhada no material das apresentações que rolaram por lá. Para visualizar o material e fazer o download, acesse esse link.]]></description>
			<content:encoded><![CDATA[<p>Ocorreu nesse mês em Berlin o <a href="http://cakefest.org/">CakeFest3</a>, para as pessoas como eu, que não puderam se fazer presente no evento, vale a pena da uma olhada no material das apresentações que rolaram por lá.</p>
<p>Para visualizar o material e fazer o download, <a href="http://cakephp.org/downloads/CakeFest/CakeFest%203%20-%20Berlin%202009">acesse esse link</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2009/07/download-apresentacoes-do-cakefest3-berlin-2009/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Download de Livros (E-books) free</title>
		<link>http://cobaia.net/2009/07/download-de-livros-e-books-free/</link>
		<comments>http://cobaia.net/2009/07/download-de-livros-e-books-free/#comments</comments>
		<pubDate>Sat, 04 Jul 2009 19:03:09 +0000</pubDate>
		<dc:creator>Vinícius Krolow</dc:creator>
				<category><![CDATA[livros]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programação]]></category>

		<guid isPermaLink="false">http://cobaia.net/?p=562</guid>
		<description><![CDATA[Navegando na internet encontrei mais uma boa opção de download de livros em geral, Além do caso específico de livros (e-books) sobre programação. O site oferece diversos livros em formato digital (e-books) de maneira free, grátis. Para os devotos de PHP assim como eu você tem alguns livros de free sobre a linguagem PHP. O [...]]]></description>
			<content:encoded><![CDATA[<p>Navegando na internet encontrei mais uma boa opção de download de livros em geral, Além do caso específico <a href="http://www.e-booksdirectory.com/programming.php">de livros (e-books) sobre programação</a>.</p>
<p>O site oferece diversos livros em formato digital (e-books) de maneira free, grátis. </p>
<p>Para os devotos de PHP assim como eu você tem alguns livros de free sobre a linguagem <a href="http://www.e-booksdirectory.com/programming.php#php">PHP</a>.</p>
<p>O único detalhe que os livros em sua maioria, são em inglês, porém no caso de programação, e livros técnicos, o conhecimento ja detido facilita a leitura, possibilitando assim pessoas que não sabem inglês adquirir conhecimento do livro.</p>
<p>Use e abuse, é free, grátis os livros, e compartilhe informações como essas. Ajude a divulgar conhecimento.</p>
]]></content:encoded>
			<wfw:commentRss>http://cobaia.net/2009/07/download-de-livros-e-books-free/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
