bu konuda kullanacağımız dosya Global.asax
projenizde bulunmuyorsa bu dosya, Add New Item dan ekleyebilirsiniz.
eklenecek kod ise aşağıda
PLAIN TEXT
ASP:
void Application_BeginRequest(object sender, EventArgs e)
{
string path = Context.Request.Path;
path = path.Replace(".html",".aspx");
Context.RewritePath(path);
}
Context.Request.Path komutu istek yapan adresi getiriyor.
daha sonra gelen string içersindeki .html değerlerini .aspx ile değiştiryor.
ve adres çubuğundaki değeri değiştirmeden .aspx sayfaya yönlendiriyor.
bu kodlar ile .aspx yerine .html olarak [...]