Chapter 9.2. Digging Into the Project Controller Methods

In the next section, we take a deeper look at how we can use MochiKit to make sending Ajax requests to the browser easier. Before we get there, let’s take a look at the WhatWhat Status project controller and how it handles these Ajax requests, and what it sends back to the browser:

import turbogears as tg import cherrypy as http import commands import socket import md5 import time import random import os from turbogears import identity, flash, validators from datetime import datetime from whatwhat import utils from textile import textile from whatwhat.widgets import widgets from whatwhat.model import (Person, Project, Risk, Note, Question, Answer, Issue, chance_codes, impact_codes, status_codes, ...

Get Rapid Web Applications with TurboGears: Using Python to Create Ajax-Powered Sites now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.