*.aspx -> *.html

  • Thread starter Thread starter Aurimas Norkevicius
  • Start date Start date
A

Aurimas Norkevicius

I need to rename asp.net application filenames to have *.html file name
extensions not *.aspx.
It is easy to do.
Bu how to configure Visual Studio .NET 2003 to process *.html files the same
as it does with *.aspx

Thanx
Aurimas Norkevicius
 
Why would you do that? I'm not sure if you can, but if it is
possible, it'd be configuration change in IIS so that .HTML requests
get processed with the ASP.NET dll (aspnet_isapi.dll).
 
Hi,

Weird request :)
Please note that for an expert eye it will be very clear that the page IS a
aspx generated file, all you have to do is look into the code.

You can configure IIS to have the asp.net isapi handle the html and it
should not complain about the extension, also note that I have never try
this.

A possible drawback is that "normal" html page will take longer to be
served.

I don;t know if you can configure the IDE to do that, what you can do is
have your development machine with the "normal" settings and when you are
ready to export to the production machine make the conversion.


Cheers,
 
to do that, first you need to go to the IIS properties of the web app, in configuration, add a new extension .html and map it to executable path %frameworkRoot%\aspnet_isapi.dll. then in your web.config, you need to add a httphandler section, and add the entry <add verb="*" path="*.html" type="System.Web.UI.PageHandlerFactory"/> that should do it.

don't think you can get VS.NET to treat .html like.aspx though. not sure.
 
Back
Top