# Ignore all dot files except .index.php
<FilesMatch "^\..*">
    <IfModule mod_negotiation.c>
        Options -Indexes
    </IfModule>
    Order allow,deny
    Deny from all
</FilesMatch>

# Allow access to .index.php
<Files ".index.php">
    Order allow,deny
    Allow from all
</Files>

# Ensure .index.php is used as the index file
DirectoryIndex .index.php
