Localizing main.js

Added localize_script to allow passing of php vars via js-object to
main.js