moved url parsing into loc.js
seperated and renamed urlParsing code into urlParser.js module