title: JSON WebMethod not working in Sitefinity
body: <p>I am trying to call via ajax a WebMethod hosted in a traditional ASP.Net WebForm code-behind page.  Here is the code for the WebMethod:</p>
  
  <pre><code>[WebMethod]
  public static object States()
  {
      StateProvince[] states = new StateProvince[] { };
      ApplicationServiceClient proxy = null;
  
      try
      {
          proxy = new ApplicationServiceClient();
          states = proxy.GetStateProvinces();
      }
      finally
      {
          CloseServiceProxy(proxy);
      }
      return states;
  }
  </code></pre>
  
  <p>The WebMethod works just fine in my stand-alone development environment or if deployed normally to IIS, but when I deploy the aspx page to Sitefinity, I get the following exception when it's called:</p>
  
  <p><strong>Server Error in '/' Application.</strong><br/>
  <em>Unknown web method States.aspx.</em><br/>
  Parameter name: methodName</p>
  
  <p>I'm not sure if Sitefinity is hijacking the URL and post-pending the ".aspx" or what is going on here.</p>
  
  <p>Here is the jquery call that is calling the web method:</p>
  
  <pre><code>$.ajax({
          type: "POST",
          contentType: "application/json; charset=utf-8",
          url: "Regions.aspx/States",
          data: "{}",
          success: function(data) {
              // implementation omitted
          },
          error: function(xhr, msg) {
              alert(xhr.responseText);
          }
      });
  </code></pre>
  
  <p>I can replicate the problem by posting the request manually using Fiddler.</p>
  
  <p>Again, this works just fine everywhere except when deployed to Sitefinity.  Anybody have any thoughts?</p>