3 ms·
Why is showing the file extension a bad thing? Why do you care if you see ".php"?
by talmand 15y ago
Why is showing the file extension a bad thing? Why do you care if you see ".php"?
- artursapek 15y agoThese are definitely a hacker's complaints. Your daughter's piano teacher won't give a shit, and he'll love that it's free.
- alanh 15y agoPerhaps, but that doesn’t make it the right choice.
- alanh 15y agoIt’s a good question. It is best practice to have well-thought-out URLs that do not have extensions. The reasons include: - If your site’s back-end technology changes, all those URLs will either break, or need redirected, or be specially handled with have extra cruft forever. - It takes longer to type and is harder to remember. - It makes your technology obvious instead of receding into the background. - It limits your ability to make awesome URLs, because now your URLs are dictated by how you name and organize your server-side scripts. (URLs are a user interface, just like GUIs, though they don’t get as much attention! http://alanhogan.com/url-as-ui http://alanhogan.com/url-as-ui) - There is no benefit to outweigh the above negatives.
- talmand 15y agoThese are excellent points. A few of them I would have a small bit of disagreement over the perceived negativity, but they are too small to bother with. I would say it's more like there is not enough benefit to outweigh the perceived, possible, and/or actual negatives. But that seems a silly statement to make in of itself. I think it revolves what your website actually is and how deeply invested you are in your URLs.