diff -r ef1c80154d6f -r 9b7067bfaa15 common/utils.py --- a/common/utils.py Tue Nov 11 16:17:50 2008 -0800 +++ b/common/utils.py Wed Nov 12 16:07:40 2008 +0100 @@ -141,6 +141,12 @@ def add_post_inline_script(self, content): self.post_inlined_scripts.append(content) + + def add_onload(self, jscode): + self.add_post_inline_script(u"""jQuery(document).ready(function () { + %s + });""" % jscode) + def add_js(self, jsfile): """adds `jsfile` to the list of javascripts used in the webpage