view changes and javascript timer