JavaScript page locker