ASP.NET PageMethods and The HTTP verb POST used to access path is not allowed

Posted by LookitsPuck on Stack Overflow See other posts from Stack Overflow or by LookitsPuck
Published on 2009-12-18T19:05:06Z Indexed on 2010/04/14 4:13 UTC
Read the original article Hit count: 1182

Filed under:
|
|
|

So, I'm using URL routing with WebForms. I run locally through the Visual Studio web server, and everything is hunky-dory. I deploy locally to IIS (XP, so it's IIS5), and therefore I need to make sure that I have my app wildcard mapped so the URL routing is handled properly.

However, doing this makes all my PageMethods fail with this message: The HTTP verb POST used to access path is not allowed

Something like /default.aspx/SendMessage does not work. I've seen solutions that exclude .svx and .asmx files, however, since this is a page method, this is a .aspx file. I know the solution is to move these files outside of .aspx, however, I have quite a few functions throughout the site in these various files. I guess I could create a single web service, and have all the functions there, however, I'm curious if there's a quick and easy way to fix this?

Thanks all, -Steve

© Stack Overflow or respective owner

Related posts about url-routing

Related posts about c#