ArunRocks

Representing Anti-Monotonistic Tendencies
  • rss
  • Home
  • A little intro to Thrissur
  • Archives
    • Search
  • Resumé
  • About Me
    • Comment policy

Learning Pylons Through Tutorials

Arun bhai | Thu, Jun 26, 2008

Web Development is now getting dominated by frameworks. After the initial hype of Rails, Python based frameworks are getting more popularity especially after the release of Google App Engine. Nobody seems to be interested in building websites using PHP, even if they are highly experienced in PHP. This could mean two things:

  1. There will be more demand in Indian IT companies for PHP skills similar to Perl scripting skills these days :mrgreen:
  2. There will be soon be a viable competitor to the immensely popular Wordpress blogging platform from the Python/Ruby world

I have nothing against Wordpress. In fact, it is one of the easiest tools to deploy. But with tools like cPanel, deployment could be no longer a deciding factor for blogging platforms.

Coming back to the topic of Python Web Frameworks, there is a multitude of options. I have used some of these framworks and found them to be ‘pythonic’ in different ways:

  • Django Well documented. Tightly Coupled and ‘Batteries Included’
  • Pylons Extremely flexibility to Plug and Play components. ‘Fun to Hack’
  • web.py Great for beginners. Entire framework ‘fits in your head’

Pylons looks most appealing to me. So far it looks like the underdog largely overshadowed by Django’s presence lacking the marketing or love it deserves. A few weeks back I would have complained about the lack of Pylons tutorials on the web. A google search brought up several links pointing to the wiki tutorial. As many have pointed out, the wiki tutorial is too long and complicated for beginners. It would easily put off a beginner. It took me quite some time to realise that the best place to start learning Pylons is the Pylons Documentation itself and the best Pylons tutorial is the Flickr Search. Going through the documentation is almost feels like reading a book with every concept explained in detail.

Pylons currently seems to the having an edge over Django for enterprise application due to its well tested interface with SQLAlchemy. Django seems to be having a fairly recent branch for SQLAlchemy integration. Pylons typically uses Python eggs and VirtualEnv for deployment which is might seem a little complex to beginners, but once you try it once it is actually quite convenient. Most of the installation can be done from the command-line and it will be nearly an independent sandbox for Pylons development. However it might take sometime to understand other aspects of using python eggs such as uninstallation and creation of new eggs. I haven’t had much success with making a portable version of my Pylons installation on Windows though :(

My favourite templating engine is Genshi because it is very designer friendly(which also means it works with the tools a Designer has, not just that it is easy for a Designer to learn). I can easily do all HTML designing directly on my Genshi templates because they are valid HTML or XML documents. Almost all of Genshi’s logic can be hidden away as attributes which is a great idea. In fact, the templates are even valid XML which makes the creation of valid HTML pages a much more natural experience. Almost all XML tools and even HTML tools like Tidy will work flawlessly on Genshi templates due to these reasons.

Once you get used to Genshi’s templates, you might even use them for static web site designing. I am sure it will save you a lot of time whenever those last minute ’sidebar redesigns for every page’ pops up.

Bookmark this to del.icio.us | Digg | Furl | Netscape | Google Bookmarks | Technorati | reddit |

Comments
3 Comments »
Categories
Python, WordPress
Comments rss Comments rss
Trackback Trackback

New, cool Look

Arun bhai | Sat, Dec 9, 2006

The new looks of the site can be credited to the awesome wordpress plugin K2. It handles AJAX search box at the right column (try it out now :) ), rotates the ArunRocks banner with every page refresh with the pictures that I have shot and of course it has a list of my favourite links at the sidebar.

ArunRocks Logo Of course, banners are not the only artwork that I did. In fact, I have been thinking about having a cool logo for ArunRocks for sometime now. Something a bit symbolic yet not too abstract. So I kind of thought about the name a bit and came up with the one on the left in about 15 mins on Photoshop.

Try to guess what the logo stands for before you read ahead. The inverted music symbol obviously stands for the two ‘r’s (in small letters) in arunrocks. If you haven’t noticed already Arun Rocks clearly hints at my initials. So the double ‘r’s have a double interpretation here. The letters are tilted and obviously ‘rocking’. The red background is also inspired from the same ‘Rock’ theme. This appears as the icon of this site on your browser, also called the favicon

Bookmark this to del.icio.us | Digg | Furl | Netscape | Google Bookmarks | Technorati | reddit |

Comments
1 Comment »
Categories
General, WordPress
Comments rss Comments rss
Trackback Trackback

Upgraded to Wordpress 2.0.5

Arun bhai | Tue, Nov 28, 2006

Hi everyone!

As you must have noticed I have upgraded to WordPress 2.0.5 - Ronan which is hardly a month old now. This is due to an unfortunate technical issue on my hosting provider. I have survived the crash by keeping a backup. But have lost some of the latest posts. So bear with me for a while…. till then, enjoy the new cool look of the site ;)

Cornered

Bookmark this to del.icio.us | Digg | Furl | Netscape | Google Bookmarks | Technorati | reddit |

Comments
2 Comments »
Categories
General, WordPress
Comments rss Comments rss
Trackback Trackback

A Nearly Perfect 404 Error Page in WordPress

Arun bhai | Wed, Mar 1, 2006
In this seemingly infinite Web
Oh! young browser thou slips
In the middle of a thousand trips
Realising what was just
The apparent reality of pages
Is nothing but a veil of certainity
404 alone is the absolute reality
-Arun

So a visitor to your website mistypes a URL, what does he see? A nearly blank page with ‘404 error’ emblazoned over it? At least that was my case until I decided to do something about it.

So many great tutorials have been written on creating a 404 Error page. The best in my opinion is at SacramentoWeb. However, the solution the author has proposed leads the user to a search box already filled with a value by second guessing what the user tried to search for. I was looking for a 404 page that already has those results below the search box.

After some research, I finally hacked up some PHP code. The result can be already seen on my site and looks quite impressive. I mean I was quickly addicted to misusing the feature by performing random searches e.g. for hollywood stuff on my site I would try typing !!!

Here is a quick summary of what to do for any template to display these results:

  1. If you haven’t modified your .htaccess file, then open it and copy paste the following as your first line

ErrorDocument 404 /index.php?error=404

  1. Copy index.php from your template and rename it to 404.php in the same directory

  2. Remove all sections dealing with posts or comments. Roughly the lines between < ?php if ( have_posts() ) and “

  3. Copy the following line to the first line of 404.php. This is to help search engine spiders indicate that this is an error page.

header(”HTTP/1.0 404 Not Found”);

  1. You can write pretty much anything in this page. Or you can download my 404 page from here

  2. Thats it!

Check out the results, I’m sure you (and your visitors) would be able appreciate the improvements in the browsing experience.

Bookmark this to del.icio.us | Digg | Furl | Netscape | Google Bookmarks | Technorati | reddit |

Comments
14 Comments »
Categories
Technical, WordPress
Comments rss Comments rss
Trackback Trackback

Wordpress Plugin: To show category Livemarks in Firefox

Arun bhai | Thu, Jun 23, 2005

Short Description

When you click on the RSS icon in the status bar of Firefox, it
automatically “discovers” some feeds for you. Would you like to see
every category of your blog appear as a seperate feed in Firefox? If
so activate this plugin. And yes, this is my first Wordpress plugin.

You can see it in action at
ArunRocks.com

How to Install it?

These are pretty standard.

  1. Download livemarks-0.5.zip. There are no additional required
    libraries

  2. Copy the livemarks.php file to your plugins folder at
    \wp-content\plugins

  3. Go to the plugins admin page and activate it

  4. There is no step 4! ;)

Full Description

Users of the Firefox and Opera browsers would familiar with live
bookmarks or livemarks. This is a browser’s in built mechanism to keep
track of any site’s RSS feeds. For eg: in firefox, an RSS icon appears
in the status bar, clicking on which will display a menu of feeds
automatically “discovered” by it. Wordpress blogs will automatically
have two feeds (varies with the template) - an Atom feed and an RSS
feed. This plugin tries to add the following to your list of of
“discovered” feeds -

  1. Every category of your blog appear as a seperate feed in Firefox if
    you are at your blog’s home page

  2. The relevant category of a post will appear if you are visiting a
    particular post

  3. The comments feed of your blog

I have a problem!

Sorry. Please post any bug reports as a comments here

Version History (Changelog)

v 0.5 (June 23, 2005)

  • Initial version uploaded

Created by

Arun Ravindran

Bookmark this to del.icio.us | Digg | Furl | Netscape | Google Bookmarks | Technorati | reddit |

Comments
12 Comments »
Categories
General, Technical, WordPress
Comments rss Comments rss
Trackback Trackback

Your Email:

Categories

  • emacs
  • General
  • greasemonkey
  • indie
  • launchy
  • Pocketmod
  • productivity
  • py2exe
  • Reviews
    • Books
    • Movies
  • Short Stories
  • Technical
    • Gaming
      • Unni
    • Python
    • WordPress

Recent Posts

  • Ledger’s Joker Chills, Thrills and Entralls
  • Reading Hindu Online Made Better with Greasemonkey
  • Better Fonts Tip: Biggest Improvement in Ubuntu Appearance
  • Best Dialogs of Salim Kumar
  • Learning Pylons Through Tutorials

Recent Comments

  • Arun bhai on Best Dialogs of Salim Kumar
  • Thomas on Best Dialogs of Salim Kumar
  • Nidhish on Best Dialogs of Salim Kumar
  • abhilash on Learning Pylons Through Tutorials
  • Bookmarks about Ubuntu on Better Fonts Tip: Biggest Improvement in Ubuntu Appearance

Meta

  • Log in
  • Entries RSS
  • Comments RSS
  • WordPress.org

Bookmarks

del.icio.us/arun_ravindran I am arun_ravindran on del.icio.us
add arun_ravindran to your network Add me to your network
rss Comments rss valid xhtml 1.1 design by jide powered by Wordpress get firefox