Custom File Extension in ASP.NET?

Posted by Peermohamedmydeen under ASP.NET on 9/20/2010 | Points: 10 | Views : 2543 | Status : [Member] | Replies : 1
Hi Friends,

Nice Day,

I am having an ASP.NET web application, in which I have few .aspx files.

I don't want to expose .aspx file extension to user in the URL. I want to give a customized file extension which can be easily changeable time to time.

Eg :

Instead of I want to show

This extension can be changeable without much effort.

Please help me.


Posted by: SheoNarayan on: 9/20/2010 [Administrator] HonoraryPlatinum | Points: 25

Not sure if you had attended yesterday's ASP.NET 4.0 In-Depth online session ( ), there Abhishek was explaining about Url routing. Using URL Routing you can achieve this very easily.

Read this article that should guide you

To see the example,

visit and modified link link, notice the extension .itfunda both links will give the same page.

Hope this will help.


Sheo Narayan

Peermohamedmydeen, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response