Fixed bugs when running in Firefox.

Page reload does not reset selected index.
Div innerText doesn't work.