Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] [OT] Creating user-friendly URLS with mod_rewrite/Apache
- Date: Fri, 18 Aug 2006 14:44:34 +0900
- From: "Edmund Edgar" <lists@example.com>
- Subject: Re: [tlug] [OT] Creating user-friendly URLS with mod_rewrite/Apache
- References: <44E53F8A.90605@example.com> <17637.19652.278717.979215@example.com>
The quick-and-dirty way to do this would be just to tell Apache to use index.php for all not-found pages:
ErrorDocument 404 /index.php
...then have index.php look at $_SERVER['REQUEST_URI'] to see what URL the user was trying to go to and figure out what to do with it.
That way people uploading static HTML content should be unaffected by your various complicated server-side shenanigans, even if they decide that they don't want to put their static pages under /japanese any more.
(Make sure that if your index.php decides that the page doesn't exist, it actually sets a 404 header, as well as telling the user that it couldn't find the page...)
- References:
Home | Main Index | Thread Index
- Prev by Date: [tlug] [OT] Creating user-friendly URLS with mod_rewrite/Apache
- Next by Date: Re: [tlug] New Custom Server for Linux - Advice Needed
- Previous by thread: [tlug] [OT] Creating user-friendly URLS with mod_rewrite/Apache
- Next by thread: Re: [tlug] [OT] Creating user-friendly URLS with mod_rewrite/Apache
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links