Include images and javascript based on url rather than relative path