Remove php files.
Add js files.
Add php extension to file not converted yet and remove `undefined` argument as its in strict mode.
Change PHP functions to JS
Merge pull request #11 from d10/js

Change PHP functions to JS.
Fix more typos
Merge pull request #12 from d10/js

Fix more typos.