Javascript: More tweaks