|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Show index.php as index
How do I configure Apache so that if a folder doesn't contain index.html but there's an index.php it will show the php-file as the index?
__________________
Fatal error on row 561: Couldn't access life - life isn't set |
|
#2
|
|||
|
|||
|
Configure it in your httpd.conf follows:
DirectoryIndex index.php index.html If you can't control the httpd.conf then you still can put this in the .htaccess. |
|
#3
|
|||
|
|||
|
>> there's an index.php it will show the php-file as the index?
Then you can't really use index.php. 1) You need to remove index.php from DirectoryIndex and append index to it: DirectoryIndex index.html index 2) Force type on index file: <FilesMatch "^index$"> ForceType application/x-httpd-php </FilesMatch> 3) Rename all index.php to index |
|
#4
|
|||
|
|||
|
Thanks, got it to work
![]() |
![]() |
| Viewing: Dev Shed Forums > System Administration > Apache Development > Show index.php as index |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|