J
jainamber
Hi,
We are in the process of launching a new asp.net site for our
client, the old site was pure html. In order to preserve the search
engine rankings of the html pages, I am trying to implement 301
redirects for the individual html pages by adding the redirect code (it
has to be done on a page by page basis) in the Session_Start event.
The steps that I took for implementing this are:
a) In IIS, I added .htm and .html to the 'configuration' section and
assigned the aspnet_isapi.dll to process those pages. I was hoping that
this change will make it work, as I did a similar thing in the past for
html -> aps site migration.
b) I changed the machine.config and added the following 2 rows for .htm
and .html in the <httphandlers> section.
<add verb="*" path="*.htm" type="System.Web.UI.PageHandlerFactory"/>
<add verb="*" path="*.html" type="System.Web.UI.PageHandlerFactory"/>
I am using System.Web.UI.PageHandlerFactory because the aspx pages were
using the same.
But the Session_Start event is still not getting called for html pages.
Can any one help me with this problem, the site launch is tomorrow.
Thanks,
Amber
We are in the process of launching a new asp.net site for our
client, the old site was pure html. In order to preserve the search
engine rankings of the html pages, I am trying to implement 301
redirects for the individual html pages by adding the redirect code (it
has to be done on a page by page basis) in the Session_Start event.
The steps that I took for implementing this are:
a) In IIS, I added .htm and .html to the 'configuration' section and
assigned the aspnet_isapi.dll to process those pages. I was hoping that
this change will make it work, as I did a similar thing in the past for
html -> aps site migration.
b) I changed the machine.config and added the following 2 rows for .htm
and .html in the <httphandlers> section.
<add verb="*" path="*.htm" type="System.Web.UI.PageHandlerFactory"/>
<add verb="*" path="*.html" type="System.Web.UI.PageHandlerFactory"/>
I am using System.Web.UI.PageHandlerFactory because the aspx pages were
using the same.
But the Session_Start event is still not getting called for html pages.
Can any one help me with this problem, the site launch is tomorrow.
Thanks,
Amber