PC Review


Reply
Thread Tools Rating: Thread Rating: 4 votes, 1.00 average.

default webpage with iis7 and web.config

 
 
Chuck
Guest
Posts: n/a
 
      23rd Jul 2010
Can I set a default webpage for a subdirectory within a website.
In a subdirectory I tried using

<system.webServer>
<defaultDocument>
<files>
<add value="Diagnostics.aspx" />
</files>
</defaultDocument>
</system.webServer>
This didn't work in the subdirectory.

vs2010 iis7
 
Reply With Quote
 
 
 
 
Jerry Weng
Guest
Posts: n/a
 
      26th Jul 2010
Hello Chuck,
Thank you for posting.
From your post, my understanding on this issue is: the defaultDocument
setting in IIS did not work for subdirectory. If I'm off base, please feel
free to let me know.

Yes, we can add a default document in the subdirectory.

By default, default documents are enabled, and IIS 7 defines the following
default document files in the ApplicationHost.config file as server-wide
defaults:

Default.htm
Default.asp
Index.htm
Index.html
Iisstart.htm

By default, when a request arrives for our site's or application's root
directory, IIS attempts to return the correct files in the order that they
appear in the <defaultDocument> element. If the Default.htm file exists,
IIS sends it to the client browser. If the Default.htm file does not exist,
IIS attempts to send the Default.asp file to the browser. IIS continues in
this manner until it attempts to send each default document file to the
client browser.

If we add a web.config in the subdirectory and configure the default
document like what you did, the list of the default documents in that
subdirectory will be like this:

Diagnostics.aspx
Default.htm
Default.asp
Index.htm
Index.html
Iisstart.htm

So I think it should work for the subdirectory. And I tested it with my
IIS, it proved to work fine.

For your issue, maybe you can try to add a <clear /> in the
<defaultDocument> schema to clear the default settings in the parent
configuration file.

<system.webServer>
<defaultDocument>
<files>
<clear />
<add value="Diagnostics.aspx" />
</files>
</defaultDocument>
</system.webServer>

If this could not make a workaround, please tell me more about the issue?
Which page did you see after you set the default doucment in the
subdirectory? Or you saw an error page?

Here is a reference document:
Default Document <defaultDocument>
http://www.iis.net/ConfigReference/s...efaultDocument

Please let me know the information above so that I can provider further
assistance on this problem. I am looking forward to your reply.

--
Sincerely,
Jerry Weng
Microsoft Online Community Support

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

With newsgroups, MSDN subscribers enjoy unlimited, free support as opposed
to the limited number of phone-based technical support incidents. Complex
issues or server-down situations are not recommended for the newsgroups.
Issues of this nature are best handled working with a Microsoft Support
Engineer using one of your phone-based incidents.
==================================================

--------------------
| Thread-Topic: default webpage with iis7 and web.config
| thread-index: AcsqrgAX7DubtyCiSout/AIst2ZOwQ==
| X-WBNR-Posting-Host: 192.12.184.2
| From: Chuck <(E-Mail Removed)>
| Subject: default webpage with iis7 and web.config
| Date: Fri, 23 Jul 2010 14:28:32 -0700
| Lines: 13
| Message-ID: <601DB216-D150-44AB-8203-(E-Mail Removed)>
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="Utf-8"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| Content-Class: urn:content-classes:message
| Importance: normal
| Priority: normal
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.4325
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| Path: TK2MSFTNGHUB02.phx.gbl
| Xref: TK2MSFTNGHUB02.phx.gbl microsoft.public.dotnet.framework.aspnet:1609
| NNTP-Posting-Host: tk2msftsbfm01.phx.gbl 10.40.244.148
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| Can I set a default webpage for a subdirectory within a website.
| In a subdirectory I tried using
|
| <system.webServer>
| <defaultDocument>
| <files>
| <add value="Diagnostics.aspx" />
| </files>
| </defaultDocument>
| </system.webServer>
| This didn't work in the subdirectory.
|
| vs2010 iis7
|

 
Reply With Quote
 
Jerry Weng
Guest
Posts: n/a
 
      28th Jul 2010
Hello Chuck,
Did you get to end of this issue?
Please feel free to reply me if you want to get more help for this problem.
---
Sincerely,
Jerry Weng
Microsoft Online Community Support

--------------------
| X-Tomcat-ID: 1219927
| References: <601DB216-D150-44AB-8203-(E-Mail Removed)>
| MIME-Version: 1.0
| Content-Type: text/plain
| Content-Transfer-Encoding: 7bit
| From: v-(E-Mail Removed) (Jerry Weng)
| Organization: Microsoft
| Date: Mon, 26 Jul 2010 02:57:17 GMT
| Subject: RE: default webpage with iis7 and web.config
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
| Message-ID: <(E-Mail Removed)>
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| Lines: 105
| Path: TK2MSFTNGHUB02.phx.gbl
| Xref: TK2MSFTNGHUB02.phx.gbl microsoft.public.dotnet.framework.aspnet:1618
| NNTP-Posting-Host: tk2tomimport1.phx.gbl 10.230.18.247
|
| Hello Chuck,
| Thank you for posting.
| From your post, my understanding on this issue is: the defaultDocument
| setting in IIS did not work for subdirectory. If I'm off base, please
feel
| free to let me know.
|
| Yes, we can add a default document in the subdirectory.
|
| By default, default documents are enabled, and IIS 7 defines the
following
| default document files in the ApplicationHost.config file as server-wide
| defaults:
|
| Default.htm
| Default.asp
| Index.htm
| Index.html
| Iisstart.htm
|
| By default, when a request arrives for our site's or application's root
| directory, IIS attempts to return the correct files in the order that
they
| appear in the <defaultDocument> element. If the Default.htm file exists,
| IIS sends it to the client browser. If the Default.htm file does not
exist,
| IIS attempts to send the Default.asp file to the browser. IIS continues
in
| this manner until it attempts to send each default document file to the
| client browser.
|
| If we add a web.config in the subdirectory and configure the default
| document like what you did, the list of the default documents in that
| subdirectory will be like this:
|
| Diagnostics.aspx
| Default.htm
| Default.asp
| Index.htm
| Index.html
| Iisstart.htm
|
| So I think it should work for the subdirectory. And I tested it with my
| IIS, it proved to work fine.
|
| For your issue, maybe you can try to add a <clear /> in the
| <defaultDocument> schema to clear the default settings in the parent
| configuration file.
|
| <system.webServer>
| <defaultDocument>
| <files>
| <clear />
| <add value="Diagnostics.aspx" />
| </files>
| </defaultDocument>
| </system.webServer>
|
| If this could not make a workaround, please tell me more about the issue?
| Which page did you see after you set the default doucment in the
| subdirectory? Or you saw an error page?
|
| Here is a reference document:
| Default Document <defaultDocument>
| http://www.iis.net/ConfigReference/s...efaultDocument
|
| Please let me know the information above so that I can provider further
| assistance on this problem. I am looking forward to your reply.
|
| --
| Sincerely,
| Jerry Weng
| Microsoft Online Community Support
|
| ==================================================
| Get notification to my posts through email? Please refer to
|
http://msdn.microsoft.com/subscripti...ult.aspx#notif
| ications.
|
| With newsgroups, MSDN subscribers enjoy unlimited, free support as
opposed
| to the limited number of phone-based technical support incidents. Complex
| issues or server-down situations are not recommended for the newsgroups.
| Issues of this nature are best handled working with a Microsoft Support
| Engineer using one of your phone-based incidents.
| ==================================================
|
| --------------------
| | Thread-Topic: default webpage with iis7 and web.config
| | thread-index: AcsqrgAX7DubtyCiSout/AIst2ZOwQ==
| | X-WBNR-Posting-Host: 192.12.184.2
| | From: Chuck <(E-Mail Removed)>
| | Subject: default webpage with iis7 and web.config
| | Date: Fri, 23 Jul 2010 14:28:32 -0700
| | Lines: 13
| | Message-ID: <601DB216-D150-44AB-8203-(E-Mail Removed)>
| | MIME-Version: 1.0
| | Content-Type: text/plain;
| | charset="Utf-8"
| | Content-Transfer-Encoding: 7bit
| | X-Newsreader: Microsoft CDO for Windows 2000
| | Content-Class: urn:content-classes:message
| | Importance: normal
| | Priority: normal
| | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.4325
| | Newsgroups: microsoft.public.dotnet.framework.aspnet
| | Path: TK2MSFTNGHUB02.phx.gbl
| | Xref: TK2MSFTNGHUB02.phx.gbl
microsoft.public.dotnet.framework.aspnet:1609
| | NNTP-Posting-Host: tk2msftsbfm01.phx.gbl 10.40.244.148
| | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
| |
| | Can I set a default webpage for a subdirectory within a website.
| | In a subdirectory I tried using
| |
| | <system.webServer>
| | <defaultDocument>
| | <files>
| | <add value="Diagnostics.aspx" />
| | </files>
| | </defaultDocument>
| | </system.webServer>
| | This didn't work in the subdirectory.
| |
| | vs2010 iis7
| |
|
|

 
Reply With Quote
 
Chuck
Guest
Posts: n/a
 
      10th Aug 2010
Seems to work now.
Maybe the default document option wasn't enabled in IIS.

thanks,


"Jerry Weng" wrote:

> Hello Chuck,
> Did you get to end of this issue?
> Please feel free to reply me if you want to get more help for this problem.
> ---
> Sincerely,
> Jerry Weng
> Microsoft Online Community Support
>
> --------------------
> | X-Tomcat-ID: 1219927
> | References: <601DB216-D150-44AB-8203-(E-Mail Removed)>
> | MIME-Version: 1.0
> | Content-Type: text/plain
> | Content-Transfer-Encoding: 7bit
> | From: v-(E-Mail Removed) (Jerry Weng)
> | Organization: Microsoft
> | Date: Mon, 26 Jul 2010 02:57:17 GMT
> | Subject: RE: default webpage with iis7 and web.config
> | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
> | Message-ID: <(E-Mail Removed)>
> | Newsgroups: microsoft.public.dotnet.framework.aspnet
> | Lines: 105
> | Path: TK2MSFTNGHUB02.phx.gbl
> | Xref: TK2MSFTNGHUB02.phx.gbl microsoft.public.dotnet.framework.aspnet:1618
> | NNTP-Posting-Host: tk2tomimport1.phx.gbl 10.230.18.247
> |
> | Hello Chuck,
> | Thank you for posting.
> | From your post, my understanding on this issue is: the defaultDocument
> | setting in IIS did not work for subdirectory. If I'm off base, please
> feel
> | free to let me know.
> |
> | Yes, we can add a default document in the subdirectory.
> |
> | By default, default documents are enabled, and IIS 7 defines the
> following
> | default document files in the ApplicationHost.config file as server-wide
> | defaults:
> |
> | Default.htm
> | Default.asp
> | Index.htm
> | Index.html
> | Iisstart.htm
> |
> | By default, when a request arrives for our site's or application's root
> | directory, IIS attempts to return the correct files in the order that
> they
> | appear in the <defaultDocument> element. If the Default.htm file exists,
> | IIS sends it to the client browser. If the Default.htm file does not
> exist,
> | IIS attempts to send the Default.asp file to the browser. IIS continues
> in
> | this manner until it attempts to send each default document file to the
> | client browser.
> |
> | If we add a web.config in the subdirectory and configure the default
> | document like what you did, the list of the default documents in that
> | subdirectory will be like this:
> |
> | Diagnostics.aspx
> | Default.htm
> | Default.asp
> | Index.htm
> | Index.html
> | Iisstart.htm
> |
> | So I think it should work for the subdirectory. And I tested it with my
> | IIS, it proved to work fine.
> |
> | For your issue, maybe you can try to add a <clear /> in the
> | <defaultDocument> schema to clear the default settings in the parent
> | configuration file.
> |
> | <system.webServer>
> | <defaultDocument>
> | <files>
> | <clear />
> | <add value="Diagnostics.aspx" />
> | </files>
> | </defaultDocument>
> | </system.webServer>
> |
> | If this could not make a workaround, please tell me more about the issue?
> | Which page did you see after you set the default doucment in the
> | subdirectory? Or you saw an error page?
> |
> | Here is a reference document:
> | Default Document <defaultDocument>
> | http://www.iis.net/ConfigReference/s...efaultDocument
> |
> | Please let me know the information above so that I can provider further
> | assistance on this problem. I am looking forward to your reply.
> |
> | --
> | Sincerely,
> | Jerry Weng
> | Microsoft Online Community Support
> |
> | ==================================================
> | Get notification to my posts through email? Please refer to
> |
> http://msdn.microsoft.com/subscripti...ult.aspx#notif
> | ications.
> |
> | With newsgroups, MSDN subscribers enjoy unlimited, free support as
> opposed
> | to the limited number of phone-based technical support incidents. Complex
> | issues or server-down situations are not recommended for the newsgroups.
> | Issues of this nature are best handled working with a Microsoft Support
> | Engineer using one of your phone-based incidents.
> | ==================================================
> |
> | --------------------
> | | Thread-Topic: default webpage with iis7 and web.config
> | | thread-index: AcsqrgAX7DubtyCiSout/AIst2ZOwQ==
> | | X-WBNR-Posting-Host: 192.12.184.2
> | | From: Chuck <(E-Mail Removed)>
> | | Subject: default webpage with iis7 and web.config
> | | Date: Fri, 23 Jul 2010 14:28:32 -0700
> | | Lines: 13
> | | Message-ID: <601DB216-D150-44AB-8203-(E-Mail Removed)>
> | | MIME-Version: 1.0
> | | Content-Type: text/plain;
> | | charset="Utf-8"
> | | Content-Transfer-Encoding: 7bit
> | | X-Newsreader: Microsoft CDO for Windows 2000
> | | Content-Class: urn:content-classes:message
> | | Importance: normal
> | | Priority: normal
> | | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.4325
> | | Newsgroups: microsoft.public.dotnet.framework.aspnet
> | | Path: TK2MSFTNGHUB02.phx.gbl
> | | Xref: TK2MSFTNGHUB02.phx.gbl
> microsoft.public.dotnet.framework.aspnet:1609
> | | NNTP-Posting-Host: tk2msftsbfm01.phx.gbl 10.40.244.148
> | | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
> | |
> | | Can I set a default webpage for a subdirectory within a website.
> | | In a subdirectory I tried using
> | |
> | | <system.webServer>
> | | <defaultDocument>
> | | <files>
> | | <add value="Diagnostics.aspx" />
> | | </files>
> | | </defaultDocument>
> | | </system.webServer>
> | | This didn't work in the subdirectory.
> | |
> | | vs2010 iis7
> | |
> |
> |
>
> .
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Hosting ASP applications without IIS... in IIS7 mode! Permissionproblems with handlers & Web.config Luis Serrano Microsoft ASP .NET 0 4th May 2009 05:13 PM
to set IE as default webpage =?Utf-8?B?ZG9uYg==?= Windows XP Internet Explorer 1 27th Oct 2004 01:59 AM
Re: Default Webpage =?Windows-1252?Q?Rob_Giordano_\=28aka:_Crash_Gordo Microsoft Frontpage 0 7th Sep 2004 06:23 PM
Default Webpage matt d. Windows XP Internet Explorer 2 30th Dec 2003 04:34 AM
Desktop webpage config Windows XP Customization 1 30th Nov 2003 03:50 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:49 AM.