title: Does IIS throw away the URL fragment on custom error pages?
body: <p>I'm using the old 404-rewrite method on a certain site that is <em>tied to IIS6</em> *.</p>
  
  <p>So if I enter</p>
  
  <pre><code>http://example.com/non-existent/path
  </code></pre>
  
  <p>it calls my error page like so</p>
  
  <pre><code>http://example.com/catch.aspx?404;http://example.com/non-existent/path
  </code></pre>
  
  <p>Great.</p>
  
  <p><em><strong>Except</em></strong> if I call the page with a fragment, like</p>
  
  <pre><code>http://example.com/non-existent/path#with-fragment
  </code></pre>
  
  <p>I get the same result as above.  I can't find the fragment anywhere:</p>
  
  <ul>
  <li>Request.Url</li>
  <li>Request.Url.OriginalString</li>
  <li>Request.UrlReferrer</li>
  <li>Request.RawUrl</li>
  <li>headers, server variables, etc</li>
  </ul>
  
  <p>This has come up because I want to resolve paths created by AJAX to their server-side versions.</p>
  
  <p>Is there any way for me to retrieve the original path from my handler?</p>
  
  <p>Thanks.</p>
  
  <p>(*) Please don't suggest I change platform.  Obviously I would if I could.</p>