javascript autorefresh for cast page