replaced anonymous function with named function declared outside of on doc ready
Merge pull request #4 from mechamanny/refactor_js

replaced anonymous function with named function declared outside of on d...