473,395 Members | 2,437 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

New Web Sites - Not Serving Up ASPX Pages (but .htm is okay)

I'm writing a small C# utility application that creates new Web Sites via
ADSI. It seems to work just fine for the most part -- meaning that IIS
Metabase entries look either identical or "different where expected" - when
comparing Web Sites created with my utility against Web Sites created
"manually" with IIS Manager. I'm comparing the sites visually (eye balling
it) with Metabase Explorer.

The problem I have with Web Sites created with my utility is that they can
serve up index.htm just fine, but not even the simplest version of
default.aspx.

The error message I get when attempting to view the page in IE6 is "The Page
cannot be displayed" and "Cannot find server or DNS Error". I have
eliminated DNS as the problem because I can PING the Web site by its domain
name (over the Internet) - and it serves up index.htm just fine.

The Default.aspx page has only <%@ Page %> at the top followed by the
usual/minimal HTML elements to define a page. When viewing the Web site
through IIS Manager - the Documents tab does in fact have a check in the
checkbox for "enable default content page" and default.aspx is listed there
as the only document (unless I swap that out for index.htm for testing
purposes).

Any suggestions for helping me determine what is causing the site to not
serve up aspx pages are greatly appreciated.

FWIW: IIS 6.0, I have stopped and restarted the Web site via IIS Manager,
and I have also recycled the application pool to which it belongs.

Thanks!
Nov 19 '05 #1
4 2886
I came up with a work-around; but I'd still appreciate any suggestions so
that I don't have to do this work-around:

The way I have found to get these sites to serve up aspx pages is to open
IIS Manager, view the properties for the site in question, go to the [Home
Directory] tab, and click [Remove] next to the Application Name textbox in
the Application Settings area. Then I immediately click on [Add] to add the
application back in. That fixed it (the site then served up aspx pages just
fine). I also recycled the Application pool - but that may have been
unnecessary.

Any ideas?

Thanks!
"Frankie" <A@B.COM> wrote in message
news:uW****************@TK2MSFTNGP10.phx.gbl...
I'm writing a small C# utility application that creates new Web Sites via
ADSI. It seems to work just fine for the most part -- meaning that IIS
Metabase entries look either identical or "different where expected" -
when comparing Web Sites created with my utility against Web Sites created
"manually" with IIS Manager. I'm comparing the sites visually (eye balling
it) with Metabase Explorer.

The problem I have with Web Sites created with my utility is that they can
serve up index.htm just fine, but not even the simplest version of
default.aspx.

The error message I get when attempting to view the page in IE6 is "The
Page cannot be displayed" and "Cannot find server or DNS Error". I have
eliminated DNS as the problem because I can PING the Web site by its
domain name (over the Internet) - and it serves up index.htm just fine.

The Default.aspx page has only <%@ Page %> at the top followed by the
usual/minimal HTML elements to define a page. When viewing the Web site
through IIS Manager - the Documents tab does in fact have a check in the
checkbox for "enable default content page" and default.aspx is listed
there as the only document (unless I swap that out for index.htm for
testing purposes).

Any suggestions for helping me determine what is causing the site to not
serve up aspx pages are greatly appreciated.

FWIW: IIS 6.0, I have stopped and restarted the Web site via IIS Manager,
and I have also recycled the application pool to which it belongs.

Thanks!

Nov 19 '05 #2
What you're missing is

1. mapping the application to aspnet_isapi.dll.

drive:\WINDOWS\MICROSOFT.NET\FRAMEWORK\Vx.x.xxxxx\ aspnet_isapi.dll

There's several extensions which you should map to aspnet_isapi.dll.

See a list at :
http://www.microsoft.com/mspress/boo...pchap/6667.asp

You probably should look at running aspnet_regiis.exe for the virtual
root you created, with the parameters you desire, typically -i .

and

2. setting the default document to "default.aspx".

You'd have to use ADSI for that :

'Only setting two properties
vDir.DefaultDoc = vDir.DefaultDoc & ",default.aspx"

'Write information back to Metabase
vDir.SetInfo

See http://www.15seconds.com/issue/980304.htm for an example.

Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Español
Ven, y hablemos de ASP.NET...
======================

"Frankie" <A@B.COM> wrote in message news:en**************@TK2MSFTNGP10.phx.gbl...
I came up with a work-around; but I'd still appreciate any suggestions so that I don't
have to do this work-around:

The way I have found to get these sites to serve up aspx pages is to open IIS Manager,
view the properties for the site in question, go to the [Home Directory] tab, and click
[Remove] next to the Application Name textbox in the Application Settings area. Then I
immediately click on [Add] to add the application back in. That fixed it (the site then
served up aspx pages just fine). I also recycled the Application pool - but that may
have been unnecessary.

Any ideas?

Thanks!
"Frankie" <A@B.COM> wrote in message news:uW****************@TK2MSFTNGP10.phx.gbl...
I'm writing a small C# utility application that creates new Web Sites via ADSI. It
seems to work just fine for the most part -- meaning that IIS Metabase entries look
either identical or "different where expected" - when comparing Web Sites created with
my utility against Web Sites created "manually" with IIS Manager. I'm comparing the
sites visually (eye balling it) with Metabase Explorer.

The problem I have with Web Sites created with my utility is that they can serve up
index.htm just fine, but not even the simplest version of default.aspx.

The error message I get when attempting to view the page in IE6 is "The Page cannot be
displayed" and "Cannot find server or DNS Error". I have eliminated DNS as the problem
because I can PING the Web site by its domain name (over the Internet) - and it serves
up index.htm just fine.

The Default.aspx page has only <%@ Page %> at the top followed by the usual/minimal
HTML elements to define a page. When viewing the Web site through IIS Manager - the
Documents tab does in fact have a check in the checkbox for "enable default content
page" and default.aspx is listed there as the only document (unless I swap that out for
index.htm for testing purposes).

Any suggestions for helping me determine what is causing the site to not serve up aspx
pages are greatly appreciated.

FWIW: IIS 6.0, I have stopped and restarted the Web site via IIS Manager, and I have
also recycled the application pool to which it belongs.

Thanks!


Nov 19 '05 #3
Thanks Juan,
What my utility was missing was a call to AppCreate2.

Basically the application wasn't being created correctly in IIS even though
I was explicitly setting all of the metabase properties (or at least those
properties that I could see through Metabase Explorer).

And, just in case others are interested in this thread, I tried
aspnet_regiis as suggested, but it didn't solve the problem. I'm not sure
what all AppCreate2 does behind the scenes, but whatever it does is
apparently necessary; and not all of its changes are apparent in Metabase
Explorer.

Thanks again!

-F
"Juan T. Llibre" <no***********@nowhere.com> wrote in message
news:%2***************@TK2MSFTNGP09.phx.gbl...
What you're missing is

1. mapping the application to aspnet_isapi.dll.

drive:\WINDOWS\MICROSOFT.NET\FRAMEWORK\Vx.x.xxxxx\ aspnet_isapi.dll

There's several extensions which you should map to aspnet_isapi.dll.

See a list at :
http://www.microsoft.com/mspress/boo...pchap/6667.asp

You probably should look at running aspnet_regiis.exe for the virtual
root you created, with the parameters you desire, typically -i .

and

2. setting the default document to "default.aspx".

You'd have to use ADSI for that :

'Only setting two properties
vDir.DefaultDoc = vDir.DefaultDoc & ",default.aspx"

'Write information back to Metabase
vDir.SetInfo

See http://www.15seconds.com/issue/980304.htm for an example.

Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Español
Ven, y hablemos de ASP.NET...
======================

"Frankie" <A@B.COM> wrote in message
news:en**************@TK2MSFTNGP10.phx.gbl...
I came up with a work-around; but I'd still appreciate any suggestions so
that I don't have to do this work-around:

The way I have found to get these sites to serve up aspx pages is to open
IIS Manager, view the properties for the site in question, go to the
[Home Directory] tab, and click [Remove] next to the Application Name
textbox in the Application Settings area. Then I immediately click on
[Add] to add the application back in. That fixed it (the site then served
up aspx pages just fine). I also recycled the Application pool - but that
may have been unnecessary.

Any ideas?

Thanks!
"Frankie" <A@B.COM> wrote in message
news:uW****************@TK2MSFTNGP10.phx.gbl...
I'm writing a small C# utility application that creates new Web Sites
via ADSI. It seems to work just fine for the most part -- meaning that
IIS Metabase entries look either identical or "different where
expected" - when comparing Web Sites created with my utility against Web
Sites created "manually" with IIS Manager. I'm comparing the sites
visually (eye balling it) with Metabase Explorer.

The problem I have with Web Sites created with my utility is that they
can serve up index.htm just fine, but not even the simplest version of
default.aspx.

The error message I get when attempting to view the page in IE6 is "The
Page cannot be displayed" and "Cannot find server or DNS Error". I have
eliminated DNS as the problem because I can PING the Web site by its
domain name (over the Internet) - and it serves up index.htm just fine.

The Default.aspx page has only <%@ Page %> at the top followed by the
usual/minimal HTML elements to define a page. When viewing the Web site
through IIS Manager - the Documents tab does in fact have a check in the
checkbox for "enable default content page" and default.aspx is listed
there as the only document (unless I swap that out for index.htm for
testing purposes).

Any suggestions for helping me determine what is causing the site to not
serve up aspx pages are greatly appreciated.

FWIW: IIS 6.0, I have stopped and restarted the Web site via IIS
Manager, and I have also recycled the application pool to which it
belongs.

Thanks!



Nov 19 '05 #4
Thanks Juan,
What my utility was missing was a call to AppCreate2.

Basically the application wasn't being created correctly in IIS even though
I was explicitly setting all of the metabase properties (or at least those
properties that I could see through Metabase Explorer).

And, just in case others are interested in this thread, I tried
aspnet_regiis as suggested, but it didn't solve the problem. I'm not sure
what all AppCreate2 does behind the scenes, but whatever it does is
apparently necessary; and not all of its changes are apparent in Metabase
Explorer.

Thanks again!

-F
"Juan T. Llibre" <no***********@nowhere.com> wrote in message
news:%2***************@TK2MSFTNGP09.phx.gbl...
What you're missing is

1. mapping the application to aspnet_isapi.dll.

drive:\WINDOWS\MICROSOFT.NET\FRAMEWORK\Vx.x.xxxxx\ aspnet_isapi.dll

There's several extensions which you should map to aspnet_isapi.dll.

See a list at :
http://www.microsoft.com/mspress/boo...pchap/6667.asp

You probably should look at running aspnet_regiis.exe for the virtual
root you created, with the parameters you desire, typically -i .

and

2. setting the default document to "default.aspx".

You'd have to use ADSI for that :

'Only setting two properties
vDir.DefaultDoc = vDir.DefaultDoc & ",default.aspx"

'Write information back to Metabase
vDir.SetInfo

See http://www.15seconds.com/issue/980304.htm for an example.

Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Español
Ven, y hablemos de ASP.NET...
======================

"Frankie" <A@B.COM> wrote in message
news:en**************@TK2MSFTNGP10.phx.gbl...
I came up with a work-around; but I'd still appreciate any suggestions so
that I don't have to do this work-around:

The way I have found to get these sites to serve up aspx pages is to open
IIS Manager, view the properties for the site in question, go to the
[Home Directory] tab, and click [Remove] next to the Application Name
textbox in the Application Settings area. Then I immediately click on
[Add] to add the application back in. That fixed it (the site then served
up aspx pages just fine). I also recycled the Application pool - but that
may have been unnecessary.

Any ideas?

Thanks!
"Frankie" <A@B.COM> wrote in message
news:uW****************@TK2MSFTNGP10.phx.gbl...
I'm writing a small C# utility application that creates new Web Sites
via ADSI. It seems to work just fine for the most part -- meaning that
IIS Metabase entries look either identical or "different where
expected" - when comparing Web Sites created with my utility against Web
Sites created "manually" with IIS Manager. I'm comparing the sites
visually (eye balling it) with Metabase Explorer.

The problem I have with Web Sites created with my utility is that they
can serve up index.htm just fine, but not even the simplest version of
default.aspx.

The error message I get when attempting to view the page in IE6 is "The
Page cannot be displayed" and "Cannot find server or DNS Error". I have
eliminated DNS as the problem because I can PING the Web site by its
domain name (over the Internet) - and it serves up index.htm just fine.

The Default.aspx page has only <%@ Page %> at the top followed by the
usual/minimal HTML elements to define a page. When viewing the Web site
through IIS Manager - the Documents tab does in fact have a check in the
checkbox for "enable default content page" and default.aspx is listed
there as the only document (unless I swap that out for index.htm for
testing purposes).

Any suggestions for helping me determine what is causing the site to not
serve up aspx pages are greatly appreciated.

FWIW: IIS 6.0, I have stopped and restarted the Web site via IIS
Manager, and I have also recycled the application pool to which it
belongs.

Thanks!



Nov 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: -[ CaMeL ]- a55m0nk | last post by:
Hi there i am creating a clan website in ASP and am making a page serving script a link sends a query to the default page and then serves the page by grabbing the HTML from a database that...
2
by: Nayt Grochowski | last post by:
I have a common Class Library that I use on a QA server which has 10+ sites that all use this library... I got everything working with the current version installed in the GAC and since some aspx...
3
by: Adam Pedder | last post by:
I'm trying to send an aspx page by email. I am quite happy sending html email from aspx pages but want to know is there is a straight forward way to render a whole page to an email? I have found...
0
by: jack | last post by:
I am getting this error on my web server runnint ASP.NET on Windows 2003, it kills the serving web pages. The only way to get the web pages to start serving is to restart the server. I can't find...
2
by: Nils Hedström | last post by:
I have a ASP.NET 1.1 project that I want to be able to deploy on my web-servers while they have real traffic (40 requests/second). When I copy the projects assembly in the bin-directory of the...
27
by: Raymond | last post by:
They say it's easier, but has anyone tried maintaining an ASP.NET site without the source code of the dlls? This was not a problem with classic ASP, all the code was almost always just in text...
24
by: John Rivers | last post by:
ASPX which means ASPX pages, the code-behind concept, User Controls, Web Controls etc. is very poorly designed and makes it extremely hard to develop professional quality web applications. ASPX...
3
by: anthonykallay | last post by:
Hi there, I am building a website for a group that has 4 companies under it. The sites are fairly similar so i want to be able to use the same set of code in the App_Code folder.. I also want to...
5
by: rmgalante | last post by:
I've been using the VS2005 Publish utility on one of my projects for about six months. I have a large site with hundreds of files, thousands if you include the code behind files. So I thought...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.