Add var for some variables' declaration to avoid polluting global namespace and for better compatibility with strict mode
Merge pull request #4 from mnjul/master

'var' for some variables' declaration to avoid polluting global namespace and for better compatibility with strict mode