add a method for running scripts on a page. the example uses