Search code examples
asp.netasp.net-mvc-2comethttp-postwebsync

ASP.Net MVC & Comet (WebSync)


I'm trying to implement comet in my ASP.Net MVC 2.0 project. I'm using WebSync from FrozenMountain. My website is coded in C# 4.0 and ASP.Net 4.0.

The comet code is triggering my MVC controller function with the [HttpPost] attribute (even though the page doesn't refresh or appear to post). Is there a way to determine what is being posted and ignore that route in my global.asax.cs?

  • Please note, I know how to ignore routes with MVC, that is not the issue.

Solution

  • The gentlemen at Frozen Mountain helped me solve the problem here

    It was hitting one of my MVC controller functions. I had to add this to my global.asax.cs

    routes.IgnoreRoute("{*allashx}", new {allashx=@".*\.ashx(/.*)?"});