Request format is unrecognized for URL unexpectedly ending in /methodname

Spent quite some time trying to figure out this error message

Request format is unrecognized for URL unexpectedly ending in /methodname 

 

This happens when i tried to send http POST to a remote computer, work fine on my local machine, from here it says.

The .NET Framework 1.1 defines a new protocol that is named HttpPostLocalhost. By default, this new protocol is enabled. This protocol permits invoking Web services that use HTTP POST requests from applications on the same computer

the solution is to add the following in the web.config

<configuration>
    <system.web>
    <webServices>
        <protocols>
            <add name="HttpGet"/>
            <add name="HttpPost"/>
        </protocols>
    </webServices>
    </system.web>
</configuration>

 

ref: http://stackoverflow.com/questions/657313/request-format-is-unrecognized-for-url-unexpectedly-ending-in