views:

27

answers:

2

I need to decide on naming conventions for a new website. I can use mod_rewrite at will.

My favourite solution would be to work with no file extension at all.

www.exampledomain.com/language/pagename

this would lead to "pagename" being treated as a directory. I would have to take that into account when using relative links.

Are there any other pitfalls I need to be aware of when doing this?

Is this legal, or are resources supposed to have a "name.prefix" structure?

Do you know of any clients that can't deal with this and start looking for /index.htm or .html?

Can you think of any SEO problems to be expected?

+2  A: 

Unless you have a very good reason to add an extension, drop it.

are resources supposed to have a "name.prefix" structure?

Not that I know of. Normally not. Resources are just a concept. A custom resource format may have that extension requirement, the other would not. It will depend.

As for SEO, the short a link is, the better. It will increase relative weight of keywords. An extension would make links longer by 4 characters or more.

Do you know of any clients that can't deal with this and start looking for /index.htm or .html?

A problem may arise if you decide to support multiple entry points.

www.exampledomain.com
www.exampledomain.com/index.html
www.exampledomain.com//index.htm
www.exampledomain.com/index

These are all different urls to search engines. Some people will be linking to you with the shortest name, the others will use the other version. Then ultimately there will be different inbound links pointing to your site start page which will essentially be the same. Search engines will detect it and see it as content duplication. Consequently, your page rank will be divided between several url versions. Finally, all except one will likely be dropped out of their index entirely. To deal with this situation, decide for one "true" url and let others perform 301 redirect (moved permanently) to the "correct" url.

Developer Art
I have traditionally used extensions since 1998 when I wrote my first web page. It seems fairly safe to drop them for web pages, I am looking for any caveats concerning more exotic clients and such. I wouldn't be surprised if there were none.
Pekka
If you look at Wikipedia pages for RSS and ATOM feeds you will see they mention some .rss and .atom extension requirement. At the same time I see most sites do not follow this format requirement. So they are probably not needed.
Developer Art
It's true, most of the sites/services around do not follow that, mainly probably for SEO reasons.
Pekka
A: 

Dropping extensions actually has the significant benefit of not tying you to a specific language. If your URLs are http://example.com/page.php and you switch to another language, you'll either lose the existing URLs (bad!) or have to fake the PHP extension (clunky).

ceejayoz