got any mod_python and cheetah resources?
February 14, 2006 6:09 PM   Subscribe

Can anyone point me to a good documentation/samples for building an app using mod_python and cheetah? (and mySQL/DBUtils etc)?

I am planning to write a webapp (internal only) that uses mod_python and cheetah to replace one that uses php and smarty. I have downloaded and installed everything but while I've used python before, I've never used mod_python or cheetah so I've been looking for some good online resources (or books) that have sample code and other useful information. I've looked around a lot but can't seem to find anything really useful. I would appreciate any help/pointers to good resources. TIA!
posted by karen to Computers & Internet (2 answers total) 1 user marked this as a favorite
I know practically nothing about Python, but here's what I've found after some Googling:

The only thing I could find about mod_python + Cheetah specifically was this brief article about using mod_python with MySQLdb and Cheetah. There's also this page on the Cheetah wiki -- do a search for mod_python, and you'll find a few code examples of integrating the two, although it looks like there's a bit of discussion about how best to do it.

It appears that most people use some kind of addtional web application framework rather than writing directly in mod_python and Cheetah. The Cheetah website and docs seem to mention Webware a lot, while this page on the Python wiki mentions Aquarium as a framework that is tightly integrated with Cheetah and can run on mod_python.

You may have more luck posting your question on the Cheetah mailing list.
posted by chrismear at 12:35 AM on February 15, 2006

Well, you probably won't find much out there because they are entirley seperate libs, but possibly complimentary. There has been a lot of movement on the Python web frameworks front lately. You should probably check out django or turbogears for a higher-level framework. Another templateing library that people seem ti like is Myghty

To start, just use mod_python. See

Once you've got that working, you can throw in Cheetah. Cheetah is just a template engine. That is, you take a template, pass in some variables, and it returns the template "filled out" with those variables. You can use this to create all kinds of documents, not just HTML.

So the idea is once you have mod_python up and running you will see that the handlers just return a string containg the HTML document. In the handler, you pass the information you want in to the cheetah template, compile it, and then return the resulting fillled out template.
posted by gus at 8:52 AM on February 15, 2006

« Older How to control multiple ICQ accounts?   |   logic of landlording: how to make money? Newer »
This thread is closed to new comments.