Refactoring the otu ajax example.