Pet peeve: Exposing file extensions on the web 2008-03-20


I keep coming across sites with pages like "/location.asp" or "/Home.aspx". I absolutely hate it.

What happens when you want to redevelop your site in another language? Do you litter 301 redirects all over the place? Or just break all your old links? Or force your webserver to treat pages ending in .asp and .aspx as PHP (or vice versa)

File extensions are not evil, but they should be used sparingly, and if you use them they should be used to represent content types served, not platform used to generate the content.

I feel particularly strongly about this today, as I've just finished a 30 page search engine optimization report for a Aardvark Media customer who's been with us for a couple of years now, yet still see people trying to access assorted ASP scripts from their old site.

The base names are often the same, but the extension is gone.

I know some of our "legacy" sites still expose ".php", but it's one of the things I'll veto for any new development.


blog comments powered by Disqus