rewrite image URL