I know you meant your question rhetorically, but I believe you can add a proxy server to the iPhone and handle any hostname trickery there.
Edit: Proxy settings can't be global, but are assigned individually for each WiFi connection.
Edit: Proxy settings can't be global, but are assigned individually for each WiFi connection.