1: [HttpPost]
2: public HttpResponseMessage SaveName(string firstName, string lastName)
3: {
4:
5: }
Yeah, good luck with that. See, right out of the box Web API doesn't allow this. I don't remember what happens, but it doesn't work the way you think it will. Rick Strahl wrote a really in-depth and quite good post about this some time ago and since I can't possibly say it any better than him, I'm going to direct you there.
While you're there you should also check out these two other posts about the exact same topic. Seriously, that guy knows what he's talking about.
No comments:
Post a Comment