convert querystring to json javascript