Looks like maybe when you're putting PHP in index.html it's not parsing it, and when you make it index.php, it's looking for index.html and not finding it.
Use .htaccess file and create/use the following:
DirectoryIndex index.html index.htm index.php
This would allow you to use index.php as a directory index page and show when you do not specify a page URL, ie
http://sitename.com/