<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/atom10full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" gd:etag="W/&quot;DEIFQXg5fSp7ImA9WhdTEU4.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769</id><updated>2011-07-08T07:48:30.625-07:00</updated><category term="timepickr" /><category term="grids" /><category term="960" /><title>fallenapples</title><subtitle type="html">Javascript, PHP, Python, RoR and some other web and software development things.</subtitle><link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/posts/default" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><generator version="7.00" uri="http://www.blogger.com">Blogger</generator><openSearch:totalResults>18</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/atom+xml" href="http://feeds.feedburner.com/Fallenapples" /><feedburner:info xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" uri="fallenapples" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><entry gd:etag="W/&quot;CEEDQX85fSp7ImA9WxFWFkk.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-361085165142837987</id><published>2010-06-04T01:52:00.000-07:00</published><updated>2010-06-04T02:11:10.125-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-06-04T02:11:10.125-07:00</app:edited><title>Good Bye Blog, Hello Wiki</title><content type="html">It has been a long time since my last update. I've been busy with other personal projects that keep me from maintain the blog. Now I have more time, but it's still difficult to write good postings.&lt;br /&gt;&lt;br /&gt;The main reason for start the blog a year ago was to document all my development facts and progress. For that purpose, the most easy way was to start a blog, because it was a known platform for me. But, after a few months after I started to use it, I found it very limited as a development resource.&lt;br /&gt;&lt;br /&gt;Previously to the blog, Codepixel author, Xabier Loureiro, suggested that I should start a personal wiki, which is more suited for continuous maintenance. I started to migrate "Fallen Apples" most useful content to a new Google Site (kind of Google wiki) and, at the moment, I agree with him. While you can achieve a similar functionality with a blog using static pages, I found more comfortable to do it on a platform like Google Sites.&lt;br /&gt;&lt;br /&gt;Now, I will use &lt;a href="http://sites.google.com/site/manelvf/"&gt;http://sites.google.com/site/manelvf/ &lt;/a&gt; to store, classify and upgrade my personal notes, as I was doing before at this blog.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-361085165142837987?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/361085165142837987/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2010/06/good-bye-blog-hello-wiki.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/361085165142837987?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/361085165142837987?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2010/06/good-bye-blog-hello-wiki.html" title="Good Bye Blog, Hello Wiki" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>2</thr:total></entry><entry gd:etag="W/&quot;AkcHSH4-fCp7ImA9WxBQEEk.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-2634757929342584963</id><published>2010-01-09T06:32:00.000-08:00</published><updated>2010-01-09T06:40:39.054-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2010-01-09T06:40:39.054-08:00</app:edited><title>Linkedin network fail</title><content type="html">I've been suffering a lot of network connections trying to access LinkedIn site from my home. In fact, I couldn't access services as accept invitations and change my profile.&lt;br /&gt;After sending an email to them, they answer me a long email with a conclusion: to connect to LinkedIn the mtu (maximun transmit unit) must be lower than usual. It seems it's a scale problem they haven't solved. A practical reference value is 1360. So, the Linux way to solve the problem is this:&lt;br /&gt;&lt;br /&gt;sudo &lt;em&gt;ifconfig&lt;/em&gt; eth0 &lt;em&gt;mtu&lt;/em&gt; 1360&lt;br /&gt;&lt;br /&gt;Where eth0 is the name of the card device (wifi is wlan0, i.e.) and 1360 is an acceptable mtu value for my connection. In distros like Fedora, maybe you have to login as root in console with "su -" or similar.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-2634757929342584963?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/2634757929342584963/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2010/01/linkedin-network-fail.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/2634757929342584963?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/2634757929342584963?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2010/01/linkedin-network-fail.html" title="Linkedin network fail" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;CU4EQ3wzcCp7ImA9WxBSGEg.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-5481820926473774866</id><published>2009-12-26T10:49:00.000-08:00</published><updated>2009-12-26T10:58:22.288-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-26T10:58:22.288-08:00</app:edited><title>Install mp3 for Audacious on Fedora Core 12</title><content type="html">Fedora Core is an outstanding distro that competes against Ubuntu, but lacks some commodities. One of them is MP3 support. We can add it installing the correct packages:&lt;br /&gt;&lt;br /&gt;1st: Find libmad rpm package. Mad is an old nice mp3 decode library. I found one here:&lt;br /&gt;&lt;a href="http://www.rpmfind.net/linux/RPM/rpmfusion/free/fedora/devel/x86_64/libmad-0.15.1b-13.fc12.i586.html"&gt;http://www.rpmfind.net/linux/RPM/rpmfusion/free/fedora/devel/x86_64/libmad-0.15.1b-13.fc12.i586.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;2nd: Find audacious plugins 'freeworld' that link mp3 library with player: &lt;a href="http://fr2.rpmfind.net/linux/RPM/rpmfusion/free/fedora/12/x86_64/audacious-plugins-freeworld-mp3-2.1-1.fc12.x86_64.html"&gt;http://fr2.rpmfind.net/linux/RPM/rpmfusion/free/fedora/12/x86_64/audacious-plugins-freeworld-mp3-2.1-1.fc12.x86_64.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;These two are for 64bit version, so maybe are not suited for your version. The most useful keyword to search for a specific package on Fedora is &lt;span style="font-weight: bold;"&gt;fcXX&lt;/span&gt; (where XX is the version number, i.e.: fc12).&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-5481820926473774866?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/5481820926473774866/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/12/install-mp3-for-audacious-on-fedora.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/5481820926473774866?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/5481820926473774866?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/12/install-mp3-for-audacious-on-fedora.html" title="Install mp3 for Audacious on Fedora Core 12" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;DUANSH08eip7ImA9WxBSFkg.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-2970233931452382711</id><published>2009-12-24T04:22:00.000-08:00</published><updated>2009-12-24T04:29:59.372-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-24T04:29:59.372-08:00</app:edited><title>F.lux: rest your eyes</title><content type="html">F.lux is a freeware (not open source) utility for Linux, Windows and Mac that changes the intensity of the screen light based on time of day. So it makes the screen darker on night and brighter on day. It also uses latitude or ZIP code to calculate sunset, so it fits to your location anywhere.&lt;div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;You can get it on: &lt;a href="http://www.stereopsis.com/flux/"&gt;http://www.stereopsis.com/flux/&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-2970233931452382711?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/2970233931452382711/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/12/flux-rest-your-eyes.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/2970233931452382711?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/2970233931452382711?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/12/flux-rest-your-eyes.html" title="F.lux: rest your eyes" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>2</thr:total></entry><entry gd:etag="W/&quot;CEYDRng4eyp7ImA9WxNaGEk.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-6792998369597985658</id><published>2009-12-03T04:09:00.001-08:00</published><updated>2009-12-03T04:09:37.633-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-03T04:09:37.633-08:00</app:edited><title>Using rsync on local folders</title><content type="html">&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;This command line synchronizes the 'test' folder with production folder, as simple deploy system. It uses the popular command 'rsync':&lt;br/&gt;rsync -crv --delete --stats --exclude "*smarty*" test/www/ www/&lt;br/&gt;&lt;br/&gt;It excludes smarty folder contents as is mostly used for auto-generated compiled templates. &lt;br/&gt;On rsync command, it doesn't use the common -a (archive) flag as it tryes to maintain date and time from old files, and some servers don't let it and provoke a warning when syncing. &lt;br/&gt;'--delete' is a potencially dangerous flag, that erases existing files if they are different than source ones.&lt;br/&gt;Other interesting flag is -n, that performs a "dry run" that shows the results without perform the copy. &lt;br/&gt;&lt;br/&gt;&lt;div class='zemanta-pixie'&gt;&lt;img src='http://img.zemanta.com/pixy.gif?x-id=0916bace-298d-82dd-837a-bacc41aa566b' alt='' class='zemanta-pixie-img'/&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-6792998369597985658?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/6792998369597985658/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/12/using-rsync-on-local-folders.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/6792998369597985658?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/6792998369597985658?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/12/using-rsync-on-local-folders.html" title="Using rsync on local folders" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;Ak4MRnY_fip7ImA9WxNVEk8.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-4705725236876602199</id><published>2009-10-22T09:29:00.001-07:00</published><updated>2009-10-22T09:29:47.846-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-10-22T09:29:47.846-07:00</app:edited><title>Remote deployment with Fabric</title><content type="html">&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;Fabric is a Python module that allows to execute scripts on remote hosts. It uses configuration scripts to perform the tasks.&lt;br/&gt;&lt;br/&gt;&lt;font face='monospace'&gt;import re&lt;br/&gt;import pysvn&lt;br/&gt;from fabric.api import run, env&lt;br/&gt;&lt;br/&gt;baseurl = ""&lt;br/&gt;&lt;br/&gt;def site(  ):&lt;br/&gt;    env.hosts = ['xxx.yyyypixel.com:22']&lt;br/&gt;    env.user = 'jailed'&lt;br/&gt;    env.baseurl = "http://pixelame.googlecode.com/svn/tags"&lt;br/&gt;&lt;br/&gt;def deploy(  ):&lt;br/&gt;&lt;br/&gt;    client = pysvn.Client()&lt;br/&gt;&lt;br/&gt;    tagList = client.ls(env.baseurl)&lt;br/&gt;&lt;br/&gt;    tagDict = {}&lt;br/&gt;&lt;br/&gt;    while True:&lt;br/&gt;        i = 0&lt;br/&gt;        for k in tagList:&lt;br/&gt;            name = k._PysvnDictBase__name&lt;br/&gt;            tag = re.compile('[^/]*$').search(name).group()&lt;br/&gt;            i += 1&lt;br/&gt;            tagDict[i] = name&lt;br/&gt;            print str(i) + ") " + tag&lt;br/&gt;&lt;br/&gt;        key = input( "Tag to export " )&lt;br/&gt;        &lt;br/&gt;        key = int( key )&lt;br/&gt;&lt;br/&gt;        if (  tagDict.has_key( key )) :&lt;br/&gt;            url = tagDict[key]&lt;br/&gt;            break&lt;br/&gt;    &lt;br/&gt;    print url&lt;br/&gt;    run( 'svn export ' + url + ' /var/www/pixelame ') // this command is executed on remote host&lt;/font&gt;&lt;br/&gt;    &lt;br/&gt;To invocate this script use:&lt;br/&gt;&lt;br/&gt;&lt;font face='monospace'&gt;fab -f script.py site deploy    &lt;/font&gt;&lt;br/&gt;&lt;br/&gt;Where script.py is the previous script and site and deploy are the methods that will be called. It connect thru ssh to the server and perform the subversion command on it with the method "run".&lt;br/&gt;This is a very simple example, but fabric can perform very complex tasks.&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;div class='zemanta-pixie'&gt;&lt;img src='http://img.zemanta.com/pixy.gif?x-id=701f58fc-b19d-8e50-94a6-e178333901c5' alt='' class='zemanta-pixie-img'/&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-4705725236876602199?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/4705725236876602199/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/10/remote-deployment-with-fabric.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/4705725236876602199?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/4705725236876602199?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/10/remote-deployment-with-fabric.html" title="Remote deployment with Fabric" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;CUcCQnYyfyp7ImA9WxNWFEg.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-2606741828370273777</id><published>2009-10-13T09:49:00.001-07:00</published><updated>2009-10-13T09:57:43.897-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-10-13T09:57:43.897-07:00</app:edited><title>Javascript custom function generator</title><content type="html">&lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;span style="font-family:verdana;"&gt;This example uses a javascript lambda function to generate a custom call inside a for loop.&lt;br /&gt;Code from an event function for an ExtJs core.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre class="ae-logs-expanded ae-pre-wrap"&gt;&lt;br /&gt;for k in ...&lt;br /&gt;var rid = content[k].id;&lt;br /&gt;rate.on( "change", function(rid) { // receives current rid value&lt;br /&gt;return function(e) {&lt;br /&gt;Ext.Ajax.request({&lt;br /&gt;url:"/rate",&lt;br /&gt;success: function() {&lt;br /&gt;},&lt;br /&gt;failure: function() {&lt;br /&gt;alert( "unable to rate" );&lt;br /&gt;},&lt;br /&gt;params:{id:rid, value: e.value}&lt;br /&gt;});&lt;br /&gt;}&lt;br /&gt;}(rid) ); // pass rid with current value&lt;br /&gt;...&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;&lt;span style="font-size:100%;"&gt;The parameter rid is evaluated 'on the fly'. If it was sent in an usual way, function would evaluate rid as last context[k].id cycled.&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;div class="zemanta-pixie"&gt;&lt;img src="http://img.zemanta.com/pixy.gif?x-id=d28cfb0e-765f-8a15-9e79-ab2da748d251" alt="" class="zemanta-pixie-img" /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-2606741828370273777?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/2606741828370273777/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/10/javascript-custom-function-generator.html#comment-form" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/2606741828370273777?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/2606741828370273777?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/10/javascript-custom-function-generator.html" title="Javascript custom function generator" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>1</thr:total></entry><entry gd:etag="W/&quot;DkEASXYyfip7ImA9WxNXGUk.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-4345688399387745481</id><published>2009-10-07T12:44:00.001-07:00</published><updated>2009-10-07T12:44:08.896-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-10-07T12:44:08.896-07:00</app:edited><title>Packing Firefox Extensions - zip command line</title><content type="html">&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;&lt;font face='monospace'&gt;&lt;big&gt;&lt;font face='tahoma'&gt;Firefox extensions are packed in a zip file, with 'xpi' extension. Linux command line to create a 'xpi':&lt;/font&gt;&lt;/big&gt;&lt;br/&gt;zip -r  dicgal * -x /*.svn* *.swp *.swo *.swn&lt;br/&gt;&lt;font face='verdana'&gt;&lt;big&gt;Where -r means recursive, dicgal is the filename of the extension, * are the files that'll be included. Last option, -x, tell what files will be excluded: vim swap files and subversion folders.&lt;br/&gt;&lt;/big&gt;&lt;/font&gt;&lt;/font&gt;&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;div class='zemanta-pixie'&gt;&lt;img src='http://img.zemanta.com/pixy.gif?x-id=3aef17a5-76eb-8ac1-9a13-fd3cf136c8b4' alt='' class='zemanta-pixie-img'/&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-4345688399387745481?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/4345688399387745481/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/10/packing-firefox-extensions-zip-command.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/4345688399387745481?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/4345688399387745481?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/10/packing-firefox-extensions-zip-command.html" title="Packing Firefox Extensions - zip command line" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;C0UBR3kyfCp7ImA9WxNXGEg.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-1198835990552419429</id><published>2009-10-06T10:47:00.001-07:00</published><updated>2009-10-06T10:47:36.794-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-10-06T10:47:36.794-07:00</app:edited><title>Debugging Firefox Extensions - console.log replacement</title><content type="html">&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;&lt;font face='verdana'&gt;Development of Firefox Extensions is not trivial. The very useful 'console.log' function call doesn't work (firebug is not loaded in the XUL). So, as alternatives, some authors suggest.&lt;br/&gt;&lt;/font&gt;&lt;br/&gt;&lt;font face='monospace'&gt;Firebug.Console.log()&lt;/font&gt;&lt;br/&gt;&lt;br/&gt;&lt;font face='tahoma'&gt;That line didn't worked on my Firefox 3 Linux enviroment. So I found this nice snippet:&lt;br/&gt;&lt;/font&gt;&lt;br/&gt; &lt;font face='verdana'&gt;&lt;font face='monospace'&gt;         function debug(aMessage) {&lt;br/&gt;            try {&lt;br/&gt;                var objects = [];&lt;br/&gt;                objects.push.apply(objects, arguments);&lt;br/&gt;                Firebug.Console.logFormatted(objects,&lt;br/&gt;TabWatcher.getContextByWindow&lt;br/&gt;(content.document.defaultView.wrappedJSObject));&lt;br/&gt;            }&lt;br/&gt;            catch (e) {&lt;br/&gt;            }&lt;br/&gt;&lt;br/&gt;            var consoleService = Components.classes["@mozilla.org/consoleservice;1"].getService&lt;br/&gt;(Components.interfaces.nsIConsoleService);&lt;br/&gt;            if (aMessage === "") consoleService.logStringMessage("(empty string)");&lt;br/&gt;            else if (aMessage != null) consoleService.logStringMessage(aMessage.toString());&lt;br/&gt;            else consoleService.logStringMessage("null");&lt;br/&gt;        }&lt;br/&gt;&lt;/font&gt;&lt;br/&gt;This function logs any javascript object to the formerly obsolete (and never forgotten) firefox console.&lt;br/&gt;&lt;br/&gt; &lt;/font&gt;&lt;br/&gt;&lt;br/&gt;&lt;div class='zemanta-pixie'&gt;&lt;img src='http://img.zemanta.com/pixy.gif?x-id=c3155fb7-5fec-8a16-ac72-665c6d499cbc' alt='' class='zemanta-pixie-img'/&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-1198835990552419429?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/1198835990552419429/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/10/debugging-firefox-extensions-consolelog.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/1198835990552419429?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/1198835990552419429?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/10/debugging-firefox-extensions-consolelog.html" title="Debugging Firefox Extensions - console.log replacement" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;DEIHSX0_fip7ImA9WxNQGEw.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-665120357868482372</id><published>2009-09-24T11:22:00.001-07:00</published><updated>2009-09-24T11:22:18.346-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-09-24T11:22:18.346-07:00</app:edited><title>No module error on Google App Engine</title><content type="html">&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;&lt;b&gt;&lt;strong&gt;&lt;small&gt;&lt;font face='tahoma'&gt;When server doesn't find a module, throws this exception:&lt;/font&gt;&lt;/small&gt;&lt;br/&gt;&lt;font face='monospace'&gt;&amp;lt;pre&amp;gt;&lt;br/&gt;class 'google.appengine.tools.dev_appserver.CouldNotFindModuleError'&lt;/font&gt;&lt;/strong&gt;&lt;font face='monospace'&gt;:  &lt;/font&gt;&lt;/b&gt;&lt;font face='monospace'&gt;&lt;br/&gt;&lt;small&gt;     &lt;/small&gt; args = () &lt;br/&gt;&lt;small&gt;     &lt;/small&gt; message = ''&lt;br/&gt;&amp;lt;/pre&amp;gt;&lt;br/&gt;&lt;/font&gt;&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;div class='zemanta-pixie'&gt;&lt;img src='http://img.zemanta.com/pixy.gif?x-id=6e746843-e283-8a04-bc9c-3296d7bc4466' alt='' class='zemanta-pixie-img'/&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-665120357868482372?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/665120357868482372/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/no-module-error-on-google-app-engine.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/665120357868482372?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/665120357868482372?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/no-module-error-on-google-app-engine.html" title="No module error on Google App Engine" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>2</thr:total></entry><entry gd:etag="W/&quot;CkENR385eSp7ImA9WxNQEk0.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-1059495785856405812</id><published>2009-09-17T08:18:00.001-07:00</published><updated>2009-09-17T08:18:16.121-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-09-17T08:18:16.121-07:00</app:edited><title>Cross-domain browser issues</title><content type="html">&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;On last days, I was trying to code my own feed reader. I was trying to find a client-side solution to feed reader system, but I haven´t found yet a good one. &lt;br/&gt;A good approach are &lt;b&gt;flXHR&lt;/b&gt; and &lt;b&gt;fJax&lt;/b&gt;, that use flash to do cross-domain queries. flXHR is a more complete solution but it still has a serious problem. As a security feature, Adobe Flash Player forbids any communitation with domains without a &lt;b&gt;crossdomain.xml&lt;/b&gt; policy file. Blogspot, wordpress, facebook and a faithful of webs have that file available, but most of them did'nt have it. &lt;br/&gt;So, a news reader has to rely on a complete server-side solution. At the moment, there is no alternative.&lt;br/&gt; &lt;br/&gt;&lt;br/&gt;&lt;div class='zemanta-pixie'&gt;&lt;img src='http://img.zemanta.com/pixy.gif?x-id=375e3f24-0df9-8ec3-9f66-289b39de05f8' alt='' class='zemanta-pixie-img'/&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-1059495785856405812?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/1059495785856405812/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/cross-domain-browser-issues.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/1059495785856405812?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/1059495785856405812?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/cross-domain-browser-issues.html" title="Cross-domain browser issues" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>2</thr:total></entry><entry gd:etag="W/&quot;DkEDQ3YyfCp7ImA9WxNRGUk.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-6274830006146020390</id><published>2009-09-11T09:33:00.001-07:00</published><updated>2009-09-14T09:11:12.894-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-09-14T09:11:12.894-07:00</app:edited><title>Setting Gnome to open Windows in different workspaces</title><content type="html">&lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;span style="font-family:verdana;"&gt;Virtual workspaces are nice. That feature is implemented in almost every window manager currently and I'm used to work with them in Gnome: one workspace for code editor and other for browser, usually Firefox. On other two desktops I use to open other browsers and/or file managers.&lt;br /&gt;It's very handy to use a shortcut to start both programs, so my one-liner script on desktop to start both applications is:&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family:verdana;"&gt;&lt;small&gt;geany &lt;i&gt;(or Aptana)&lt;/i&gt; | firefox &lt;/small&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family:verdana;"&gt;But how can I start the apps in different workspaces? The answer is simple: &lt;a href="http://burtonini.com/blog/computers/devilspie" target="_blank"&gt;Devil's pie&lt;/a&gt;. Devilspie is a tool let's the user configure window application launchs.&lt;br /&gt;Once installed, you can launch it via command line for testing. When you feel comfortable, simply add it to the window manager session startup (in Ubuntu: System -&amp;gt; Preferences -&amp;gt; Settings).&lt;br /&gt;To customize an application launch, you have to create lisp-style &lt;i&gt;s-expressions&lt;/i&gt; on custom files on &lt;i&gt;./devilspie&lt;/i&gt; folder. Only one expression is allowed per file. Custom S-Expression:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;small&gt;&lt;span style="font-family:sans-serif;"&gt;(if&lt;br /&gt;  (is (application_name) “firefox”)&lt;br /&gt;  (set_workspace 2))&lt;/span&gt;&lt;/small&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Simple and powerful.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Last thing to remember: &lt;span style="font-style: italic; font-weight: bold;"&gt;set_workspace&lt;/span&gt; do not work in metacity, use &lt;span style="font-style: italic; font-weight: bold;"&gt;set_viewport&lt;/span&gt;. Metacity uses viewports instead of workspace, despite Gnome shows "workspace" label on context menus and docs.&lt;br /&gt;&lt;br /&gt;&lt;div class="zemanta-pixie"&gt;&lt;img src="http://img.zemanta.com/pixy.gif?x-id=375e3f24-0df9-8ec3-9f66-289b39de05f8" alt="" class="zemanta-pixie-img" /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-6274830006146020390?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/6274830006146020390/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/setting-gnome-to-open-windows-in.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/6274830006146020390?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/6274830006146020390?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/setting-gnome-to-open-windows-in.html" title="Setting Gnome to open Windows in different workspaces" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;CkcHSX4-cCp7ImA9WxNRGUk.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-8677616646639233846</id><published>2009-09-10T04:44:00.000-07:00</published><updated>2009-09-14T07:53:58.058-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-09-14T07:53:58.058-07:00</app:edited><title>New application on Google App Engine</title><content type="html">&lt;div style="text-align: justify;"&gt;A few weeks ago, I started an experiment with the &lt;span style="font-style: italic;"&gt;&amp;lt;canvas&amp;gt;&lt;/span&gt; element. That element let's javascript developers create simple 2D vector graphics on Firefox, Safari and Opera browsers. Currently is not available for IE, but there is an interesting proyect to do an &lt;a href="http://code.google.com/p/explorercanvas/"&gt;abstraction layer&lt;/a&gt;.&lt;br /&gt;&lt;/div&gt;One of the goals of the experiment was to replicate the behaviour of an old VGA game I'd coded 12 years ago: the player controls a character that moves across the screen, showing a nice photograph. When player reaches a percent of completeness, the level is finished and game starts on the next level.&lt;br /&gt;The old VGA game used memory buffers to create the effect. &lt;span style="font-style: italic;"&gt;canvas&lt;/span&gt; element doesn't use pixel buffers neither anything similar but vector graphics. Instead of pixel masks, you must indicate mask shape with commands. So, to achieve the effect, my solution was to create one mask by each horizontal line, so I could take the control of how much surface was &lt;span style="font-style: italic;"&gt;cleaned&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;var screen = [320,200]; // screen dimensions&lt;br /&gt;&lt;br /&gt;var limit = [] &lt;/span&gt;&lt;span style="font-size:85%;"&gt;// control structure of the masks&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;// limit assignation&lt;br /&gt;for(var k = 0; k &amp;lt; 0; k++) {&lt;br /&gt;    &lt;/span&gt;&lt;span style="font-size:85%;"&gt;limit[k] = [mask.min,mask.max]&lt;br /&gt;&lt;/span&gt;&lt;span style="font-size:85%;"&gt;}&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;The main drawback of this approach is that browser has to redraw each mask line on each frame, so it can be very slow on old (and a few newer) machines.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://code.google.com/p/canvasexperiment/"&gt;Code for this and other canvas related experiments.&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://lume.appspot.com/"&gt;The project running in its current state at the Google App Engine.&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-8677616646639233846?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/8677616646639233846/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/new-application-on-google-app-engine.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/8677616646639233846?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/8677616646639233846?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/new-application-on-google-app-engine.html" title="New application on Google App Engine" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;AkIHQX4zfSp7ImA9WxNRFU8.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-7807779799170026317</id><published>2009-09-09T13:35:00.001-07:00</published><updated>2009-09-09T13:35:30.085-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-09-09T13:35:30.085-07:00</app:edited><title>Setting a lightweight development enviroment</title><content type="html">&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;Aptana Studio was the last web development IDE I used. It's based on Eclipse, so it can be very "overbloated". Furthermore, it's not confortable to customize it sometimes. &lt;br/&gt;For that reasons, I changed my development enviroment recently. My new tools:&lt;br/&gt;&lt;ul&gt;&lt;li&gt;&lt;b&gt;Geany&lt;/b&gt;. Lightweight text-editor with many useful plugins. Cross-platform.&lt;/li&gt;&lt;li&gt;&lt;b&gt;NautilusSVN&lt;/b&gt;. Nice set of SVN (version control) scripts for Nautilus, Gnome navigator. It tries to mimetize TortoiseSVN for Windows.&lt;/li&gt;&lt;li&gt;&lt;b&gt;Meld&lt;/b&gt;. Diff utility. Complements SVN functions with a nice file differences display. &lt;/li&gt;&lt;li&gt;and &lt;b&gt;Firefox&lt;/b&gt;.&lt;/li&gt;&lt;/ul&gt;Also I use different virtual desktops for each application. I lose javascript code completion, but I'm yet used to work without it!&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;div class='zemanta-pixie'&gt;&lt;img src='http://img.zemanta.com/pixy.gif?x-id=46136da7-f27b-82b9-96ad-c8177cb9ddb2' alt='' class='zemanta-pixie-img'/&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-7807779799170026317?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/7807779799170026317/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/setting-lightweight-development.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/7807779799170026317?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/7807779799170026317?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/setting-lightweight-development.html" title="Setting a lightweight development enviroment" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>2</thr:total></entry><entry gd:etag="W/&quot;D0INR3wzfCp7ImA9WxNRE08.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-3477793354181914610</id><published>2009-09-07T05:13:00.001-07:00</published><updated>2009-09-07T05:13:16.284-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-09-07T05:13:16.284-07:00</app:edited><title>Firebug issues on POST forms submit</title><content type="html">I really like FireBug. I think it&amp;#39;s the best tool for web deveploment in years and it&amp;#39;s and amazing contribution to open source code and development. But sometimes it does some really tricky, odd things.&lt;br&gt;&lt;br&gt;Recently I&amp;#39;d serialized a form with jQuery :&lt;br&gt; &lt;br&gt;&lt;font size="2"&gt;&lt;span style="font-family: times new roman,serif;"&gt;var params = $(&amp;quot;commentForm&amp;quot;).serialize(); // get a string with form parameters&lt;/span&gt;&lt;br&gt;&lt;/font&gt;&lt;br&gt;then I use it in a generic ajax call:&lt;br&gt; &lt;br&gt;$.ajax(&lt;br&gt;   method: &amp;quot;POST&amp;quot;,&lt;br&gt;   params: params,&lt;br&gt;   ....&lt;br&gt;);&lt;br&gt;&lt;br&gt;Too normal until debugging the result of the query in Firebug. The server&amp;#39;s answer contains the params of the form:&lt;br&gt;&lt;span style="font-family: times new roman,serif;"&gt;&lt;br&gt; Array(&lt;/span&gt;&lt;br style="font-family: times new roman,serif;"&gt;&lt;span style="font-family: times new roman,serif;"&gt;   id:&lt;b&gt;4893&lt;/b&gt;&lt;/span&gt;&lt;br style="font-family: times new roman,serif;"&gt;&lt;span style="font-family: times new roman,serif;"&gt;)&lt;/span&gt;&lt;br&gt; &lt;br&gt;But firebug window shows:&lt;br&gt;&lt;br&gt;&lt;span style="font-family: times new roman,serif;"&gt;Array(&lt;/span&gt;&lt;br style="font-family: times new roman,serif;"&gt; &lt;span style="font-family: times new roman,serif;"&gt;   id:&lt;b&gt;0&lt;/b&gt;&lt;/span&gt;&lt;br style="font-family: times new roman,serif;"&gt; &lt;span style="font-family: times new roman,serif;"&gt;)&lt;/span&gt;&lt;br&gt; &lt;br&gt;Different results. Why? Firebug does not capture Firefox query. Instead of that, it replies the query &lt;b&gt;without&lt;/b&gt; the parameters. So it can show wrong results to developers who are debugging their ajax posts.&lt;br&gt;I have noticed that behavior in Linux and formerly in Windows with different versions of Firebug, so don&amp;#39;t trust it! &lt;br&gt;  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-3477793354181914610?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/3477793354181914610/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/firebug-issues-on-post-forms-submit.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/3477793354181914610?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/3477793354181914610?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/firebug-issues-on-post-forms-submit.html" title="Firebug issues on POST forms submit" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;AkcFRXozcCp7ImA9WxNRFUQ.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-4189051274036634983</id><published>2009-09-05T04:46:00.001-07:00</published><updated>2009-09-10T08:53:34.488-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-09-10T08:53:34.488-07:00</app:edited><title>How-to develop a Firefox Extension in Linux (I)</title><content type="html">Based on last available tutorial from Mozilla at this date, &lt;a href="https://developer.mozilla.org/en/Extensions"&gt;Mozilla Extensions&lt;/a&gt;. For a detailed explanation consult there.&lt;br /&gt;&lt;br /&gt;Setting a develpment enviroment:&lt;br /&gt;&lt;br /&gt;For Ubuntu:&lt;br /&gt;&lt;br /&gt;To run more than a single firefox instance:&lt;br /&gt;&lt;pre&gt;/usr/bin/firefox -no-remote -P dev&lt;/pre&gt;&lt;br /&gt;"about:config" settings:&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;javascript.options.showInConsole&lt;/strong&gt; = &lt;strong&gt;true&lt;/strong&gt;&lt;br /&gt;&lt;strong&gt;nglayout.debug.disable_xul_cache&lt;/strong&gt; = &lt;strong&gt;true&lt;br /&gt;&lt;/strong&gt;&lt;strong&gt;browser.dom.window.dump.enabled&lt;/strong&gt; = &lt;strong&gt;true&lt;br /&gt;&lt;/strong&gt;&lt;strong&gt;javascript.options.strict&lt;/strong&gt; = &lt;strong&gt;true&lt;/strong&gt;&lt;br /&gt;&lt;strong&gt;extensions.logging.enabled&lt;/strong&gt; = &lt;strong&gt;true&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: normal;"&gt;Extension Developer Extension : &lt;a href="http://addons.mozilla.org/en-US/firefox/addon/7434/"&gt;http://addons.mozilla.org/en-US/firefox/addon/7434/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Profile extension folder: &lt;/span&gt;&lt;/strong&gt;~/.mozilla/&lt;b&gt;firefox/[profile name]/extensions&lt;br /&gt;&lt;/b&gt;where&lt;b&gt; [profile name]  &lt;/b&gt;= name of the profile, usually with prefix generated by Firefox.&lt;br /&gt;&lt;br /&gt;Extensions are ZIP compressed files, but to develop using a more convenient folder structure:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Create a file in the profile extension folder with a GUID or your mail as name.&lt;/li&gt;&lt;li&gt;Write the absolute path of the xpi package as content.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;Extension Wizard to generate skeleton: &lt;a href="http://ted.mielczarek.org/code/mozilla/extensionwiz/"&gt;http://ted.mielczarek.org/code/mozilla/extensionwiz/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-4189051274036634983?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/4189051274036634983/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/how-to-develop-firefox-extension-in.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/4189051274036634983?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/4189051274036634983?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/09/how-to-develop-firefox-extension-in.html" title="How-to develop a Firefox Extension in Linux (I)" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;DkQMQn8ycCp7ImA9WxJaFUQ.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-6594545676091363289</id><published>2009-08-06T14:18:00.000-07:00</published><updated>2009-08-06T14:33:03.198-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-08-06T14:33:03.198-07:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="grids" /><category scheme="http://www.blogger.com/atom/ns#" term="timepickr" /><category scheme="http://www.blogger.com/atom/ns#" term="960" /><title>Using timepickr plugin with 960 grid system</title><content type="html">&lt;span style="font-style: italic;"&gt;960.gs&lt;/span&gt; is a good and very simple web framework I'm using to build prototypes of my web experiments. It has many "default" css styles that can interfire with your web desired behavior.&lt;br /&gt;First serious problem I've found was using jQuery original "timepickr" plugin. The plugin lets the user choose a time in form very quickly. When I tried to apply it, the cell elements appeared too separated from themselves.&lt;br /&gt;Using firebug to debug the CSS classes, I found a very simple solution: declare a new class for that.&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;&lt;span style="font-family: arial;"&gt;&lt;span style="font-family: times new roman;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(153, 153, 153);font-size:85%;" &gt;&lt;span style="font-family: courier new;"&gt;.ui-timepickr li {&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    margin-left:0px;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;}&lt;br /&gt;&lt;span style="font-size:100%;"&gt;&lt;span style="color: rgb(0, 0, 0);"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;For each element &lt;li&gt; with class 'ui-timepickr', remove left margin. This declaration preserves the custom elements style, while showing page grid layout correctly.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-6594545676091363289?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/6594545676091363289/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/08/using-timepickr-plugin-with-960-grid.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/6594545676091363289?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/6594545676091363289?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/08/using-timepickr-plugin-with-960-grid.html" title="Using timepickr plugin with 960 grid system" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>0</thr:total></entry><entry gd:etag="W/&quot;C0MBSH86eSp7ImA9WxJbF0U.&quot;"><id>tag:blogger.com,1999:blog-7998118083823350769.post-2381942392664988426</id><published>2009-07-28T04:24:00.000-07:00</published><updated>2009-07-28T04:44:19.111-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-07-28T04:44:19.111-07:00</app:edited><title>First steps on Django</title><content type="html">While I have been coding in PHP for last years, I think that it's time to change. In the next few weeks, I will try a few nice web frameworks.&lt;br /&gt;First stone will be Django. This Python framework looks interesting:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Google supports it with its fork for "Google App Engine".&lt;/li&gt;&lt;li&gt;Its community has grown a lot on last year since the launch of version 1.0.&lt;/li&gt;&lt;li&gt;Python is now a very mature and consolidated language.&lt;/li&gt;&lt;li&gt;It has a nice and simple template system.&lt;/li&gt;&lt;li&gt;Its development server seems handy.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;My former colleague, Juanjo Alvarez, has done in his blog a &lt;a href="http://juanjoalvarez.net/es/detail/2009/jul/1/mini-analisis-de-django/"&gt;deep analisys of Django&lt;/a&gt; (in Spanish).&lt;br /&gt;&lt;br /&gt;First problems: as a web developer, I am coding now in WinXP for compatibility reasons. The development server does not answer after a few develpmente cycles. Restarting again the server on the same port doesn´t work. My solution at the moment is to restart the server in a different port (8001 instead of default 8000, i.e.).&lt;br /&gt;Users who work in Linux doesn't report any problem with the development server. It seems a configuration or version bug.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7998118083823350769-2381942392664988426?l=thefallenapples.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://thefallenapples.blogspot.com/feeds/2381942392664988426/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://thefallenapples.blogspot.com/2009/07/first-steps-on-django.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/2381942392664988426?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/7998118083823350769/posts/default/2381942392664988426?v=2" /><link rel="alternate" type="text/html" href="http://thefallenapples.blogspot.com/2009/07/first-steps-on-django.html" title="First steps on Django" /><author><name>Manel Villar</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="29" height="32" src="http://3.bp.blogspot.com/_SK76UJndqwE/Sm1-qwwEZ7I/AAAAAAAACTg/NjYJ7Nf7_K0/S220/eu.bmp" /></author><thr:total>2</thr:total></entry></feed>

