Tuesday, December 27, 2005

Playing with Django -1

Finish the tutorial on Ado Programming with Python. Basically if you understand the concept of the first few chapters, it apply to the whole tutorial, so it is really helpful to spend more time to get yourself familiar with it at first, then speed up later.

So, now I am playing with Django a bit, if you don't aready know, Django is Web Framework, as in Ruby on Rails, but this is in Python. So, probably I will write down a bit of my progress, other than a note for my own learning, it is as a mean to record how far I go as well.

So, first, I downloaded the Django Code in tar.gz format from here. It is now at 0.90 version, so obviously still not a stable one. As mentioned in the documentation section, it require a database as well, since I already have MySQL installed (for my project in Xoops), I don't really have to install again, just create a new database for Django purpose, if you are not too sure about creating a database in command line, it is something like this (as shown in the documentation),

CREATE DATABASE database_name;"

Or, better still, use phpMyAdmin(as front-end GUI to help user configure MySQL database minus all those commands, neat). Which I have installed in my PC due to Xoops as well.

So, since the tutorial is to create a web poll, I have created a database called "webpoll" as well, talking about creativity, :-).

So, the next thing, I unzip the Django code to Python load point. In command prompt, change directory to the Django folder, and run "python setup.py install". This start some batch process, it then stop with a message, a file named something like "setuptool" need to be installed, then it try to downlaod from the net, so if you have your machine connected, just let it do the download, in a few minutes, it should be done.

No comments: