title: notfound.html is not found
body: <p>Pretty sure based on various examples (like the one <a href="http://www.thesitewizard.com/archive/custom404.shtml" rel="nofollow">here</a>) I set things up correctly:</p>
  
  <p>1) I created a file 'notfound.html' in the root directory of my site</p>
  
  <p>2) I'm running xampp, ie. Apache web server, so based on the stuff I've read, Apache looks for a notfound.html in the root directory of a site when a non-existent page is typed in the browser, such as www.mysite.com/NotAValidPage.html and uses that notfound.html for the 404 error message</p>
  
  <p>Here's what I've tried and the result of each attempt:</p>
  
  <p><strong>1test)</strong> I put my own notfound.html in my site's root directory and enter a non-existent page</p>
  
  <p><strong>1result)</strong> my notfound.html is not used, but instead the default 404 error from (I guess) my web server, appears and says:</p>
  
  <pre><code> Object not found!
  
        The requested URL was not found on this server. If you entered the URL manually please check your spelling and try 
         again.
  
  If you think this is a server error, please contact the webmaster.
  
  Error 404
  localhost
  2/14/2012 9:11:29 AM
  Apache/2.2.17 (Win32) mod_ssl/2.2.17 OpenSSL/0.9.8o PHP/5.3.4 mod_perl/2.0.4 Perl/v5.10.1 
  </code></pre>
  
  <p><strong>2test)</strong> I next added an .htaccess file to the root folder of my site and added this line in this .htaccess file:</p>
  
  <pre><code>    ErrorDocument 404 /notfound.html
  </code></pre>
  
  <p>then I typed a non-existent page into my browser.</p>
  
  <p><strong>2result)</strong> I still see a default 404 error page, not my notfound.html, only this time the default error page says:</p>
  
  <pre><code> Not Found
  
   The requested URL /mysite.com/indsadfaex.php was not found on this server.
  
   Additionally, a 404 Not Found error was encountered while trying 
   to use an ErrorDocument to handle the request.
  </code></pre>
  
  <p><strong>3test)</strong> I then modified my .htaccess file by removing the '/' before the name of my custom 404 error page filename as follows:
               <strong>ErrorDocument 404 notfound.html</strong>         </p>
  
  <p><strong>3result)</strong> Now when I type my site name followed by a non-existent page, I no longer see the default 404 error page -- the browser window is completely blank except for the following at the top left corner:</p>
  
  <pre><code>    notfound.html
  </code></pre>
  
  <p>Not sure what to do here, seems like I am missing some subtlety -- any ideas are really appreciated.</p>
  
  <p><strong>EDIT:</strong>  I doubt it matters but there are 2 other statements in my .htaccess file for redirection situations:</p>
  
  <pre><code>  RewriteEngine on
    RewriteRule ^([^/\.]+)$ theHandlerPage.php?theArgumentPassedIn=$1 [L]
  </code></pre>
  
  <p>The regex here simply says 'go to the very end of the URL typed in and match a contiguous string of characters iff no '/' or '.' is in that contiguous stream of characters, then pass those in by way of $_GET[theArgumentPassedIn'] to the file theHandlerPage.php.</p>
  
  <p>I don't think this rewrite rule is coming into play here because it will not match on a bad page name such as mysite/badpage.html because of the '.' in badpage.html.</p>
  
  <hr>
  
  <p>Okay -- I discovered a bit of unexpectedness.</p>
  
  <p>1) I move my <strong>notfound.html</strong> error file to the parent directory of my site -- whereas before the file was located at <code>c:/xampp/htdocs/mysite/notfound.html</code>,  I have now moved this file to <code>c:/xampp/htdocs/notfound.html</code>.</p>
  
  <p>2) then I use <strong>ErrorDocument 404 /notfound.html</strong>   inside of my <code>.htaccess</code> file, which is located at <code>c:/xampp/htdocs/mysite/.htaccess</code></p>
  
  <p>And now when I type in the browser bar <code>mysite/aBadfilename.html</code>, my <strong>404 notfound.html</strong> is showing up fine.</p>
  
  <p>BUT THIS IS UNWORKABLE.  I cannot have my <code>notfound.html</code> reside in the parent directory of my site, because I need a different notfound.html for each site I develop.  I must be able to put my site's notfound.html in its folder space, ie. inside <code>c:/xampp/htdocs/mysite.</code></p>
  
  <p>Because <code>c:/xampp/htdocs</code> is the root folder of all web sites on the server.</p>
  
  <p>Why is my web server looking for my-site's <code>notfound.html</code> in the <code>c:/xampp/htdocs</code> root directory instead of <code>c:/xampp/htdocs/mysite</code>?  After all, I type mysite/badfile.html so the web server (in my opinion) should understand that <strong>notfound.html</strong> is in the <code>c:/xampp/htdocs/mysite</code> folder space.</p>