how to set web.config default page for php index file
Asked Answered
G

1

9

I'm trying to start my web site on iis server and I use php for that.

every thing is fine on server but defaultDocument.

how can I set that on web.config file.

  <?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <defaultDocument enabled="true">
            <files>
                <remove value="default.aspx" />
                <remove value="iisstart.htm" />
                <remove value="index.html" />
                <remove value="index.htm" />
                <remove value="Default.asp" />
                <remove value="Default.htm" />
                <add value="index.php" />
            </files>
        </defaultDocument>
    </system.webServer>
</configuration>

this is the default xml and I try other thing like:

<clear />

or try to remove other pages...

any Idea how can I set this file?

Generation answered 13/5, 2013 at 12:28 Comment(1)
I'm using this one right now... check answerGeneration
G
11

after some more researches, the only suitable config was this...

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <defaultDocument>
            <files>
                <clear />
                <add value="index.php" />
                <add value="index.html" />
                <add value="index.htm" />
            </files>
        </defaultDocument>
    </system.webServer>
    <system.data>
        <DbProviderFactories>
            <remove invariant="System.Data.SqlServerCe.4.0" />
            <add invariant="System.Data.SqlServerCe.4.0" name="Microsoft® SQL Server® Compact 4.0" description=".NET Framework Data Provider for Microsoft SQL Server Compact" type="System.Data.SqlServerCe.SqlCeProviderFactory, System.Data.SqlServerCe, Version=4.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91" />
        </DbProviderFactories>
    </system.data>
</configuration>
Generation answered 7/8, 2013 at 9:46 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.