Added support for mobile browsers.

also fixed a glitch with Chrome.