Refactor js
Enable to configure host_url to post queries