<?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"
	>

<channel>
	<title>Brainfault</title>
	<atom:link href="http://www.brainfault.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.brainfault.com</link>
	<description>Just another blog</description>
	<pubDate>Sat, 19 Apr 2008 11:29:37 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
	<language>en</language>
			<item>
		<title>Install python-mysql (MySQLdb) on Mac OSX</title>
		<link>http://www.brainfault.com/2008/04/18/install-python-mysql-mysqldb-on-mac-osx/</link>
		<comments>http://www.brainfault.com/2008/04/18/install-python-mysql-mysqldb-on-mac-osx/#comments</comments>
		<pubDate>Fri, 18 Apr 2008 19:30:43 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[mysql]]></category>

		<category><![CDATA[python]]></category>

		<category><![CDATA[django]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/?p=21</guid>
		<description><![CDATA[To connect to a MySQL database from Django or a python script you have to install MySQLdb. The installation of the package on MacOSX is not straightforward, so here is a small howto.

Download and unpack the MySQLdb package
Edit the setup-posix.py file, and change the line below:

mysql_config.path = "mysql_config"
to
mysql_config.path = "/usr/local/mysql/bin/mysql_config"

Note: you have to specify the [...]]]></description>
			<content:encoded><![CDATA[<p>To connect to a MySQL database from Django or a python script you have to install <a href="http://sourceforge.net/projects/mysql-python/">MySQLdb</a>. The installation of the package on MacOSX is not straightforward, so here is a small howto.</p>
<ul>
<li>Download and unpack the MySQLdb package</li>
<li>Edit the setup-posix.py file, and change the line below:
<pre name="code" class="python">
mysql_config.path = "mysql_config"
to
mysql_config.path = "/usr/local/mysql/bin/mysql_config"
</pre>
<p><strong>Note:</strong> you have to specify the path to your mysql_config unless you have installed mysql.com package for mac</li>
<li>Build
<pre name="code" class="python">
 python setu.py clean
 python setup.py build
 sudo python setup.py install
</pre>
<p>If you get this compile error</p>
<pre name="code" class="c">
/usr/include/sys/types.h:92: error: duplicate ‘unsigned’
/usr/include/sys/types.h:92: error: two or more data types in declaration specifiers
</pre>
<p>edit the _mysql.c file and comment this line</p>
<pre name="code" class="c">
#define uint unsigned int
</pre>
</p>
</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2008/04/18/install-python-mysql-mysqldb-on-mac-osx/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Selectbox replacement plugin Update</title>
		<link>http://www.brainfault.com/2008/04/05/selectbox-replacement-plugin-update/</link>
		<comments>http://www.brainfault.com/2008/04/05/selectbox-replacement-plugin-update/#comments</comments>
		<pubDate>Sat, 05 Apr 2008 19:22:58 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[jquery]]></category>

		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/?p=20</guid>
		<description><![CDATA[I&#8217;m releasing a new version of the plugin. This release is stable enough and fix a major bug dealing with scrollbar in IE but another major bug popup this time with safari, the list just doesn’t appear when you click on the replaced select box, I tried the latest Webkit build (r31623) and it works [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m releasing a new version of the plugin. This release is stable enough and fix a major bug dealing with scrollbar in IE but another major bug popup this time with safari, the list just doesn’t appear when you click on the replaced select box, I tried the latest Webkit build (r31623) and it works properly, if someone can point me to a debugging tool for Mac Safari I&#8217;ll be thankful !</p>
<p>Note : <a href="http://www.brainfault.com/jquery-plugins/jquery-selectbox-replacement/">I&#8217;ve setup an independant page for the plugin</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2008/04/05/selectbox-replacement-plugin-update/feed/</wfw:commentRss>
		</item>
		<item>
		<title>MySQL ERROR 1005 (HY000): Can&#8217;t create table &#8216;Table.frm&#8217; (errno: 150)</title>
		<link>http://www.brainfault.com/2008/02/15/mysql-error-1005-hy000-cant-create-table-tablefrm-errno-150/</link>
		<comments>http://www.brainfault.com/2008/02/15/mysql-error-1005-hy000-cant-create-table-tablefrm-errno-150/#comments</comments>
		<pubDate>Fri, 15 Feb 2008 11:22:05 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[mysql]]></category>

		<category><![CDATA[symfony]]></category>

		<category><![CDATA[propel]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/2008/02/15/mysql-error-1005-hy000-cant-create-table-tablefrm-errno-150/</guid>
		<description><![CDATA[If you&#8217;re trying to import an sql file using symfony propel-insert-sql and you get this error :
ERROR 1005 (HY000): Can't create table 'Table.frm' (errno: 150)
check this command output it&#8217;s really helpful :
mysql>SHOW ENGINE INNODB STATUS;
it will give you the detailed explanation about the most recent innoDB foreign key error.
If you are using a mysqldump file [...]]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re trying to import an sql file using symfony propel-insert-sql and you get this error :</p>
<pre name="code" class="sql">ERROR 1005 (HY000): Can't create table 'Table.frm' (errno: 150)</pre>
<p>check this command output it&#8217;s really helpful :</p>
<pre name="code" class="sql">mysql>SHOW ENGINE INNODB STATUS;</pre>
<p>it will give you the detailed explanation about the most recent innoDB foreign key error.<br />
If you are using a mysqldump file add these commands at the top and bottom of the sql file</p>
<pre name="code" class="sql">
SET FOREIGN_KEY_CHECKS = 0; -- TOP
SET FOREIGN_KEY_CHECKS = 1; -- BOTTOM
</pre>
<p>that will disable constraints check</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2008/02/15/mysql-error-1005-hy000-cant-create-table-tablefrm-errno-150/feed/</wfw:commentRss>
		</item>
		<item>
		<title>New release of jQuery selectbox replacement</title>
		<link>http://www.brainfault.com/2008/02/10/new-release-of-jquery-selectbox-replacement/</link>
		<comments>http://www.brainfault.com/2008/02/10/new-release-of-jquery-selectbox-replacement/#comments</comments>
		<pubDate>Sun, 10 Feb 2008 06:52:41 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[javascript]]></category>

		<category><![CDATA[jquery]]></category>

		<category><![CDATA[selectbox]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/2008/02/10/new-release-of-jquery-selectbox-replacement/</guid>
		<description><![CDATA[I&#8217;ve just released a new version of Selectbox replacement plugin which fix the highlight issue and added escape keyboard binding. A new css class has been created for the selected element - previously I was using the hoverClass - so now we have 2 options hoverClass and selectedClass.
Example
You can view a working example here 
Download
Download
]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve just released a new version of Selectbox replacement plugin which fix the highlight issue and added escape keyboard binding. A new css class has been created for the selected element - previously I was using the hoverClass - so now we have 2 options hoverClass and selectedClass.</p>
<h2>Example</h2>
<p><a href="http://www.brainfault.com/demo/selectbox/0.5/">You can view a working example here</a> </p>
<h2>Download</h2>
<p><a href="http://www.brainfault.com/download/jquery.selectbox-0.5.zip">Download</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2008/02/10/new-release-of-jquery-selectbox-replacement/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Textmate for linux with gedit</title>
		<link>http://www.brainfault.com/2007/12/15/textmate-for-linux-with-gedit/</link>
		<comments>http://www.brainfault.com/2007/12/15/textmate-for-linux-with-gedit/#comments</comments>
		<pubDate>Sat, 15 Dec 2007 14:31:17 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[gedit]]></category>

		<category><![CDATA[symfony]]></category>

		<category><![CDATA[textmate]]></category>

		<category><![CDATA[ubuntu]]></category>

		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/2007/12/15/textmate-for-linux-with-gedit/</guid>
		<description><![CDATA[Gedit snippets plugins allow smart code completion ala Textmate. Here is how to configure gedit to enable this feature :
1/ Download this file it contains symfony smart completion code 
2/ Click &#8220;Edit&#8221; > &#8220;Preferences&#8221; and then select the plugins tab, scroll down unitl you found &#8220;Snippets&#8221;, Check it 



3/ Go to &#8220;Tools&#8221; > &#8220;Manage Snippets&#8221; [...]]]></description>
			<content:encoded><![CDATA[<p>Gedit snippets plugins allow smart code completion ala Textmate. Here is how to configure gedit to enable this feature :<br />
1/ <a href="http://www.brainfault.com/wp-content/uploads/2007/12/symfony.tar.gz">Download this file it contains symfony smart completion code </a><br />
2/ Click &#8220;Edit&#8221; > &#8220;Preferences&#8221; and then select the plugins tab, scroll down unitl you found &#8220;Snippets&#8221;, Check it </p>
<div style="text-align:center;border 2px solid #ccc;">
<a href='http://www.brainfault.com/wp-content/uploads/2007/12/screenshot-gedit-preferences.png' title='screenshot-gedit-preferences.png'><img src='http://www.brainfault.com/wp-content/uploads/2007/12/screenshot-gedit-preferences.thumbnail.png' alt='screenshot-gedit-preferences.png' /></a>
</div>
<p>3/ Go to &#8220;Tools&#8221; > &#8220;Manage Snippets&#8221; and click on the import button you should now see the new snippets. </p>
<div style="text-align:center;border 2px solid #ccc;">
<a href='http://www.brainfault.com/wp-content/uploads/2007/12/screenshot-snippets-manager.png' title='Snippet Manager'><img src='http://www.brainfault.com/wp-content/uploads/2007/12/screenshot-snippets-manager.thumbnail.png' alt='Snippet Manager' /></a>
</div>
<p><strong>NB :</strong> The triggers are the small words between parentheses, for example for link_to(&#8230;) just type linkto<strong>TAB</strong> and tab again to move from first parameter to the next one. I&#8217;ll update this post soon with a full list of triggers.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2007/12/15/textmate-for-linux-with-gedit/feed/</wfw:commentRss>
		</item>
		<item>
		<title>SelectBox replacement : Version 0.4 released</title>
		<link>http://www.brainfault.com/2007/12/12/selectbox-replacement-version-04-released/</link>
		<comments>http://www.brainfault.com/2007/12/12/selectbox-replacement-version-04-released/#comments</comments>
		<pubDate>Wed, 12 Dec 2007 06:53:06 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[javascript]]></category>

		<category><![CDATA[jquery]]></category>

		<category><![CDATA[selectbox]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/2007/12/12/selectbox-replacement-version-04-released/</guid>
		<description><![CDATA[A quick note to let you know that I&#8217;ve released a new version of the jquery selectbox replacement plugin, this is mainly a bug fix release. I would like to thank &#8216;pawel maziarz&#8217; for his contribution.
I&#8217;ve received a request to make a license modification and I did :) , so now the plugin is licensed [...]]]></description>
			<content:encoded><![CDATA[<p>A quick note to let you know that I&#8217;ve released a new version of the jquery selectbox replacement plugin, this is mainly a bug fix release. I would like to thank &#8216;pawel maziarz&#8217; for his contribution.<br />
I&#8217;ve received a request to make a license modification and I did :) , so now the plugin is licensed under a dual license GPL/MIT </p>
<h2>Changelog </h2>
<ul>
<li>Fix width when the select element is in a hidden div</li>
<li>Add a unique id for the generated li to avoid conflict with other selects and empty select values</li>
</ul>
<h2>Download</h2>
<p><a href="http://www.brainfault.com/download/jquery.selectbox-0.4.zip">Download</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2007/12/12/selectbox-replacement-version-04-released/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Select Box replacement</title>
		<link>http://www.brainfault.com/2007/07/23/select-box-replacement/</link>
		<comments>http://www.brainfault.com/2007/07/23/select-box-replacement/#comments</comments>
		<pubDate>Mon, 23 Jul 2007 13:45:15 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[javascript]]></category>

		<category><![CDATA[jquery]]></category>

		<category><![CDATA[selectbox]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/2007/07/23/select-box-replacement/</guid>
		<description><![CDATA[This is an unobtrusive jQuery plugin that allows you to replace the HTML select box with a styled dropdown menu. 
Why ? 
As most of us, I hate IE6 but I have to deal with it. At work, our users use exclusively IE6 so you can imagine the nightmare! I came across the IE bug [...]]]></description>
			<content:encoded><![CDATA[<p>This is an unobtrusive jQuery plugin that allows you to replace the HTML select box with a styled dropdown menu. </p>
<h2>Why ? </h2>
<p>As most of us, I hate IE6 but I have to deal with it. At work, our users use exclusively IE6 so you can imagine the nightmare! I came across the IE bug where the select box stay always on top of any div even if you define a z-index value, more on the subject can be found <a href="http://www.brainjar.com/css/positioning/default5.asp">here</a> and <a href="http://blogs.msdn.com/ie/archive/2006/01/17/514076.aspx">here</a>. So this plugin try to resolve the problem by replacing the select box by dropdown menu.
</p>
<h2>Know issues </h2>
<ul>
<li>On Mac with both Safari and FF when you select a value using Enter key the form is submitted, it seems that &#8220;preventDefault&#8221; is not working. If anyone has an idea about how to resolve this, just drop me a mail or a leave a comment.</li>
<li>When an option is selected using the mouse and when you reopen the list the selected option is not highlighted anymore.</li>
</ul>
<h2>Example</h2>
<p><a href="http://www.brainfault.com/demo/selectbox/">You can view a working example here</a> </p>
<h2>Download</h2>
<p><a href="http://www.brainfault.com/download/jquery.selectbox-0.3.zip">Download</a></p>
<p><strong>NB:</strong> A new version can be located <a href="http://www.brainfault.com/2008/02/10/new-release-of-jquery-selectbox-replacement/">here</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2007/07/23/select-box-replacement/feed/</wfw:commentRss>
		</item>
		<item>
		<title>PHP get namespaces</title>
		<link>http://www.brainfault.com/2007/07/14/php-get-namespaces/</link>
		<comments>http://www.brainfault.com/2007/07/14/php-get-namespaces/#comments</comments>
		<pubDate>Fri, 13 Jul 2007 22:27:35 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/2007/07/14/php-get-namespaces/</guid>
		<description><![CDATA[The long awaited feature has been added to the PHP repository yesterday using the Dimitry Stogov’s implementation.
Define a namespace :

namespace Zend::DB;
class Connection
{
    //code
}
function connect()
{
    //code
}

You can import namespaces or class name like this:

require 'Zend/Db/Connection.php';
import Zend::DB;
import Zend::DB::Connection as DbConnection;
$x = new Zend::DB::Connection();
$y = new DB::connection();
$z = new DbConnection();
DB::connect();

]]></description>
			<content:encoded><![CDATA[<p>The long awaited feature has been added to the <a href="http://news.php.net/php.zend-engine.cvs/5894">PHP repository</a> yesterday using the Dimitry Stogov’s implementation.<br />
Define a namespace :</p>
<pre name="code" class="php">
namespace Zend::DB;
class Connection
{
    //code
}
function connect()
{
    //code
}
</pre>
<p>You can import namespaces or class name like this:</p>
<pre name="code" class="php">
require 'Zend/Db/Connection.php';
import Zend::DB;
import Zend::DB::Connection as DbConnection;
$x = new Zend::DB::Connection();
$y = new DB::connection();
$z = new DbConnection();
DB::connect();
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2007/07/14/php-get-namespaces/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Oracle 11g - live stream launch</title>
		<link>http://www.brainfault.com/2007/07/10/oracle-11g-live-stream-launch/</link>
		<comments>http://www.brainfault.com/2007/07/10/oracle-11g-live-stream-launch/#comments</comments>
		<pubDate>Tue, 10 Jul 2007 19:45:21 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<category><![CDATA[oracle]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/2007/07/10/oracle-11g-live-stream-launch/</guid>
		<description><![CDATA[After 4 long years, Oracle will launch their new version &#8220;Oracle 11g&#8221; tomorrow (July 11) with a live stream from New York.
This version will contain no less than 482 new features (more details) seen in the beta version revealed 9 months ago like data compression, Speed boost, the ability to create a standby snapshot for [...]]]></description>
			<content:encoded><![CDATA[<p>After 4 long years, <a href="http://www.oracle.com/features/hp/oracle-database-11g.html">Oracle will launch their new version &#8220;Oracle 11g&#8221;</a> tomorrow (July 11) with a live stream from New York.</p>
<p>This version will contain no less than 482 new features (<a href="http://www.dba-oracle.com/oracle11g/oracle_11g_new_features.htm">more details</a>) seen in the beta version revealed 9 months ago like data compression, Speed boost, the ability to create a standby snapshot for regression testing, online application upgrade (hot patching), a native Java &#038; PL/SQL compilers and the more interesting feature for me is a re-engineered driver for PHP.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2007/07/10/oracle-11g-live-stream-launch/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Pin plugin reloaded</title>
		<link>http://www.brainfault.com/2007/07/07/pin-plugin-reloaded/</link>
		<comments>http://www.brainfault.com/2007/07/07/pin-plugin-reloaded/#comments</comments>
		<pubDate>Sat, 07 Jul 2007 15:30:13 +0000</pubDate>
		<dc:creator>brainfault</dc:creator>
		
		<category><![CDATA[javascript]]></category>

		<category><![CDATA[jquery]]></category>

		<category><![CDATA[pin]]></category>

		<guid isPermaLink="false">http://www.brainfault.com/2007/07/07/pin-plugin-reloaded/</guid>
		<description><![CDATA[a little while ago, a friend wrote the pin plugin based on prototype and since that time I decided to move to jquery so I decided to update it.
About
The goal of this plugin is just to remember field&#8217;s values when needed by the user.
Why ?
Imagine that you have a (big) form that it&#8217;s extensively used [...]]]></description>
			<content:encoded><![CDATA[<p>a little while ago, a <a href="http://ajax.phpmagazine.net/2007/04/pin_plugin_for_prototype_remem.html">friend wrote the pin plugin based on prototype</a> and since that time I decided to move to jquery so I decided to update it.</p>
<h2>About</h2>
<p>The goal of this plugin is just to remember field&#8217;s values when needed by the user.</p>
<h2>Why ?</h2>
<p>Imagine that you have a (big) form that it&#8217;s extensively used and for some reasons the value of some fields are repeated every time, the plugin can solve this (writting/selecting) issue by providing a mechanism to choose and save some fields.</p>
<h2>How ?</h2>
<p>Like other jquery plugins you just have to call :</p>
<pre lang="javascript">
$(element).pin();
</pre>
<h2>Dependencies</h2>
<ul>
<li><a href="http://www.jquery.com/">jQuery</a> of cource</li>
<li><a href="http://www.stilbuero.de/2006/09/17/cookie-plugin-for-jquery/">Cookie plugin</a></li>
</ul>
<h2>Download</h2>
<ul>
<li><a href="/demo/pin/">you can check the demo</a></li>
<li>Download <a href="http://www.brainfault.com/demo/pin/jquery.pin.js">latest version</a></li>
</ul>
<h2>ToDo</h2>
<ul>
<li>move pin images to options, so you can set your own images</li>
<li>add multiple select, radio and checkbutton support</li>
</ul>
<h2>Changelog</h2>
<p>Not yet</p>
]]></content:encoded>
			<wfw:commentRss>http://www.brainfault.com/2007/07/07/pin-plugin-reloaded/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>

<!-- Dynamic Page Served (once) in 1.828 seconds -->
