[SWLUG] URL rewrite help

Steve Hill steve at nexusuk.org
Fri Jan 7 23:54:23 UTC 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Tue, 21 Dec 2004, Neil Jones wrote:

> I have a series of  .html files in a directory that I wish to replace
> with .php files totally invisibly.
>
> That is to say I want the .php files to work as if they were still .html
> files.
>
> so filename.php would still be found by a link to filename.html

Can't for the life of me remember how to do the rewrite rules for it, but 
some food for thought: the w3c recommend not referencing the file 
extension in URIs for exactly this reason.

I.e. instead of http://www.example.com/foo/bar.html you can just reference 
http://www.example.com/foo/bar which means you can change the underlying 
technology without changing the URIs.  (so "bar" could actually be 
bar.xhtml, bar.php, bar.pl, etc on the server side and the clients never 
need to know).

  - Steve       Jabber: steve at nexusuk.org     Web: http://www.nexusuk.org/

      Servatis a periculum, servatis a maleficum - Whisper, Evanescence

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)
Comment: Public key available at http://www.nexusuk.org/pubkey.txt

iD8DBQFB3yEw5zUOsIV3bqERAsysAJsHvwjAlIIts++y2++CoSNFEs4UwACeMFCW
7PrKkFk8e9k5NB0suGKg0KA=
=dQth
-----END PGP SIGNATURE-----



More information about the Swlug mailing list