You talk about "the server" as if all servers are the same. I know from experience that some servers will require you to handle it differently though. In my case I'm thinking of Java+Tomcat+apache-httpcommons
In short, yes, some servers will require it to be handled differently.