Refactors script into seperate file and fix #25

Refactors the javascript into a .js file
Only "#button_submit" is now disabled 
clicking "Random" will now trigger the "change" event on the text field