title: Ajax post to ASP .NET 2.2 Razor page gives 404 error
body: <p>I can't seem to get this to work with the latest .NET Core 2.2 Razor.
  I hard-coded the URL just to make sure it is correct. The ajax script is inside a partial view, but I did test to move the script into the main page with the same 404 result.</p>
  
  <pre><code>$.ajax({
      type: 'POST',
      url: 'https://localhost:44349/Admin/Catalog/Products/Edit?handler=Filter&amp;id=1',
      success: function (data) {
          alert("success");
      },
      error: function (xhr, textStatus, error) {
          alert(xhr.statusText);
      }
  });
  </code></pre>
  
  <p>And here is my handler:</p>
  
  <pre><code>public IActionResult OnPostFilter(int id)
          {
              return new JsonResult("test");
          }
  </code></pre>
  
  <p>I disabled AntiForgery Token in Startup just to make sure that wasn't causing my problem:</p>
  
  <pre><code>    services.AddMvc().AddRazorPagesOptions(o =&gt;
      {
          o.Conventions.ConfigureFilter(new IgnoreAntiforgeryTokenAttribute());
      });
  </code></pre>