Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Sep 19, 2007 07:52 PM by OWScott
Sep 10, 2007 02:08 AM|LINK
I have been trying to work my issues out with my ASP.NET sites and IIS. Recently I downloaded a Starter Kit and built it and then published it to my server. After doing so, I went to the web address and got the following error:
Line 10: <customErrors mode="RemoteOnly"/>
Line 11: <compilation debug="true"/>
Line 12: <authentication mode="Forms">
Line 13: <forms loginUrl="Default.aspx" protection="Validation" timeout="300"/>
Line 14: </authentication>
Line 10: <customErrors mode="RemoteOnly"/>
It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS. (c:\inetpub\wwwroot\qwertytech\web.config line 19)
It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS. (c:\inetpub\wwwroot\qwertytech\web.config line 20)
Version Information: Microsoft .NET Framework Version:2.0.50727.832; ASP.NET Version:2.0.50727.832
What could I have done when i just built it and then published it?
Sep 13, 2007 02:17 PM|LINK
You dropped your new site into a qwertytech folder under your site root. The issue is that the web.config settings require that that folder be marked as an application. The <authentication> tag cannot be run in a normal folder.
Since it's a standalone site that you want to be marked as an application anyway, just go to IIS and edit the properties for the qwertytech folder. In the home directory tab, create the folder as an application. This will essentially create that project
as its own website within a website and the /qwertytech folder will be set as an application root. Then that setting will be allowed to be processed.
Sep 14, 2007 02:24 AM|LINK
I'm lost on what to do... I'm new to IIS. Can you give a little more details?
Sep 14, 2007 02:59 PM|LINK
Sure. Fire up IIS and expand the websites and your website. You'll see your folder which should have a normal looking icon. Right-click on the folder and click properties. Now, take note of the application pool (I'm assuming IIS 6). Click on "Create".
Now, due to a bug that has always been there, the app pool will change to DefaultAppPool (which may be what you have anyway). Now change the application pool to what it's supposed to be and click Apply. Now you'll have a folder that has become an application
root which should take care of that issue for you.
Sep 14, 2007 10:06 PM|LINK
Okay, I launched my IIS6 and got the following:
Okay, whenever I expand the Web Sites, i see little globes. I don't get a folder...... I'm a little confused.
Sep 14, 2007 10:15 PM|LINK
You need to drill down one level deeper to the qwertytech folder under the QWERTYtech site. That's the one that needs to be marked as an application. That should do the trick.
Sep 15, 2007 03:34 AM|LINK
Well when you click on the globe that says QWERTYtech, it has all of my site folders directly under it.... do i need to have a folder called QWERTYtech with all of my site stuff in it?
Sep 15, 2007 10:45 PM|LINK
Based on your error message, it's a folder called QWERTYtech that has the web.config file:
(c:\inetpub\wwwroot\qwertytech\web.config line 19)
Is that the root of your site c:\inetpub\wwwroot, or c:\inetpub\wwwroot\qwertytech?
The issue is happening because you don't have the c:\inetpub\wwwroot\qwertytech folder marked as an application. Let me give the answer for both situations:
Situation A: c:\inetpub\wwwroot\qwertytech is the root of your site and web.config is in the site root.
If you get that error from that, you have a unique situation. Go to the home directory tab of the site properties and there is an application section. Click on the "Create" button and it should add it back again. That should only be missing if you deleted
it manually. It's there by default.
Situation B: c:\inetpub\wwwroot is the root of the site and qwertytech is a subfolder. In that case, yes, you'll have a folder in the qwertytech site called qwertytech. That needs to be marked as an application.
I hope that helps.
Sep 16, 2007 05:14 PM|LINK
Okay, I'm looking at my Home Directory tab and there is no "create" button. This is what I have in my application settings:
Application Name: Default Application <BTN>REMOVE</BTN>
Starting Point: <QWERTYtech>
Execute Permissions: Script Only
Application Pool: DefaultAppPool
This is what I have... I'm not quite sure what to do...
Sep 16, 2007 10:06 PM|LINK
Humm, what you have there is correct, as far as a website is concerned. The Default Application shows that your site is configured correctly. Let's step back and look at the big picture. Can you confirm the following? This is what I believe you are saying
that you have:
If all of those are true then . . . well . . . they can't all be true. ;) Which one of those are incorrect?