# Apache20



## rbizzell33 (Mar 15, 2010)

I am installing atmail webmail client. I extract the directory to my /usr/local give correct ownership and permission and I type in the url to see if the php script will start the installation but It only shows the directory. I have done before and it worked and now it isn't working. I check my php.ini and that is correct.


----------



## SirDice (Mar 15, 2010)

Set the correct DirectoryIndex.


----------



## rbizzell33 (Mar 15, 2010)

Can you explain a little more I thought If I set document root in httpd.conf it will work and I point it to that directory. /usr/local/atmail/webmail and that is what my document root is set to


----------



## DutchDaemon (Mar 15, 2010)

Add index.php to the DirectoryIndex directive in httpd.conf. Pretty sure it's in every PHP faq/tutorial out there.


----------



## rbizzell33 (Mar 16, 2010)

This is what I entered in httpd.conf 


```
<IfModule mod_dir.c>
      IfModule mod_php5.c>
          DirectoryIndex index.php index.php5 index.html
         </IfModule>
```

Restarted apache20 and this time this shows up


```
<?php
/*
* Copyright (c) 2009-2010 ATMAIL. All rights reserved
* See [url]http://atmail.com/license.php[/url] for license agreement
*/

//apd_set_pprof_trace();

//session_cache_limiter('private'); //IE7 https file download work around
/* rather implimented.
TODO: try to find a way to have normal caching on if detected as https IE7 or other FAILER
header("Pragma: ");
header("Cache-Control: ");
*/

include_once('bootloader.php');
 
if($frontController)
{
	$frontController->dispatch();   

	Zend_Session::writeClose();
	Zend_Registry::get('log')->info('Hit closing down. Hit time: ' . round( ( microtime(true) - DEBUG_START_MT ),3 ) . ' seconds');
}


?>
```


----------



## DutchDaemon (Mar 16, 2010)

@rbizzell33: format your posts, please.


----------



## DutchDaemon (Mar 16, 2010)

I don't have any Apache 2.0 around, but in Apache 2.2 it simply looks like this:


```
#
# DirectoryIndex: sets the file that Apache will serve if a directory
# is requested.
#
<IfModule dir_module>
        DirectoryIndex index.html index.html.var index.php    
</IfModule>
```

Note that you have incomplete tags in your statement.

It may have been mod_dir in 2.0. See http://httpd.apache.org/docs/2.0/mod/mod_dir.html#directoryindex


----------



## rbizzell33 (Mar 16, 2010)

I got it right thanks this is the first time i had to do this. I appreciate youe help


----------



## DutchDaemon (Mar 16, 2010)

Does this mean it's solved or that you made a typo here?


----------



## rbizzell33 (Mar 17, 2010)

I made some typos


----------



## DutchDaemon (Mar 17, 2010)

Try this, plain and simple.


```
<IfModule mod_dir.c>
          DirectoryIndex index.php index.php5 index.html
</IfModule>
```


----------



## rbizzell33 (Mar 17, 2010)

Thanks that  worked. I appreciate your help. You the man


----------

