Common code for url/options handling
Change http output mimetype to xml