Last post Aug 24, 2017 06:35 AM by Billy Liu
Aug 23, 2017 09:03 AM|georgedk4|LINK
Please bear with me - i am from a PHP/Apache background but i have been asked to look at why a .NET/IIS application is not running. I am receiving the following error message when visiting the URL via localhost or via the domain name:-
Server Error in '/WS6' Application
This type of page is not served.
Description: The type of page you have requested is not served because it has been explicitly forbidden. The extension '.vbhtml' may be incorrect. Please review the URL below and make sure that it is spelled correctly.
Requested URL: /WS6/s2.vbhtml
So its trying to run a vbhtml file. I have set this up as a standalone website and then as an application of a parent website and i keep receiving that error message. I have also made the following setting changes:-
- Ensured that all users have full access to the WS6 folder;
- Ensured that .NET framework v4.0 - is running. It definitely is as the error page says so at the bottom;
- Under "ASP" i can see that "Script Language" is set to "VBScript" - i believe thats ok;
- Under "Handler Mappings", i can see a whole series of settings for VB - e.g. "vbhtml-integrated-4.0", "vbhtml-ISAPI-4.0_64bit" etc;
- Under "Request Filtering", i have ensured that ".vbhtml" is allowed;
- Under "MIME Types", I have added and enabled the ".vbhtml" and set its MIME type to "application/octet-stream";
- Under "Directory Browsing", i have enabled and disabled it to no avail;
- Under "Default Document", i have added "myfile.vbhtml" and pushed it to the top;
Each time i was stopping the server, starting it back up again and then revisiting the page and every single time i received the same error message.
I have also checked the IIS error logs and i am continually receiving 403 forbidden HTTP error codes.
Can anyone guide me in the right direction please (bearing in mind i don't have a background in .NET).
Some further information about the application:-
A POST request is made to /WS6/s2.vbhtml whenever someone logs into their software program. That code is then supposed to take the contents of the POST and add it to a MS-SQL database on the same server. The application contains the following
And thats it - there are no other files than that....
Thanks in advance
Aug 24, 2017 06:35 AM|Billy Liu|LINK
It seems that you are trying to directly access a Razor page outside of the ~/Views folder
Please try to set webpages:Enabled to true in web.config file.
<add key="webpages:Enabled" value="true" />
And you could refer to the link below for more information:
Disclaimer: This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not
tested any software or information found on these sites; therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. There are inherent dangers in the use of any software found
on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.