Forum Moderators: phranque

Message Too Old, No Replies

/1 as html

         

solokron

12:55 pm on Dec 11, 2006 (gmt 0)

10+ Year Member



I am drawing a blank. How can I have the file "1", no extension, be displayed as html?

Thanks!

solokron

12:56 pm on Dec 11, 2006 (gmt 0)

10+ Year Member



Or any number for that matter. 1, 2, 3, 4.

Thanks!

maccas

1:22 pm on Dec 11, 2006 (gmt 0)

10+ Year Member



You mean 1 as 1.html? Have mod_rewrite?

Options +FollowSymLinks
RewriteEngine On
RewriteRule ^([0-9])$ $1.html [L,NC]

solokron

2:29 pm on Dec 11, 2006 (gmt 0)

10+ Year Member



Like I said, no extension. I have it figured out though.

<filesmatch "^[0-9]+$">
ForceType html
</filesmatch>