changing get_host call to use httprequest object

standalone get_host function is no longer present in django 1.5