[javascript] Parse an URL in JavaScript