move static page js to own file