Reputation: 556
How to set startup page for a specific folder?
Upvotes: 2
Views: 3990
Reputation: 556
ok i found solution.
<system.webServer>
<defaultDocument enabled="true">
<files>
<clear/>
<add value="Pages/Default.aspx"/>
</files>
</defaultDocument>
<modules runAllManagedModulesForAllRequests="true"/>
Upvotes: 1
Reputation: 8198
Just name it default.aspx and that's it.
UPDATE:
May be you check if default.aspx in defined in IIS as default document or not.
Check links below. It'll guide you to check if settings of IIS are OK or not.
http://www.iis.net/learn/web-hosting/web-server-for-shared-hosting/default-documents
http://www.iis.net/configreference/system.webserver/defaultdocument
Setting Default WebPage in IIS 7.5
Hope it helps
Upvotes: 0
Reputation: 11104
First you have to add web.config file in folder and in your web.config
add this rule
<defaultDocument enabled="true">
<files>
<clear/>
<add value="index.aspx"/>
</files>
</defaultDocument>
<modules runAllManagedModulesForAllRequests="true"/>
Upvotes: 1