added some js goodies
fixed typo