Added a couple of extensions.
Adjusted javascript if statements.