0

I want to know which of the following urls is best to use:

http://www.website.com/index.php?i=123
http://www.website.com/i123/item-name/
http://www.website.com/item-name/i123/
http://www.website.com/i123-item-name.htm
http://www.website.com/i/123-item-name.htm
tshepang
  • 12,111
  • 21
  • 91
  • 136
user153887
  • 29
  • 5

2 Answers2

7

I prefer http://www.website.com/i123/item-name/, due to the fact that you can still parse http://www.website.com/i123/ easily if someone omits the name, and it's clear what is the name and what is not.

Amber
  • 507,862
  • 82
  • 626
  • 550
  • 1
    2nded. Although leaving out the ID altogether looks even nicer if you can enforce unique names. – mpen Dec 19 '09 at 04:07
  • Looks nicer, but hurts those who'd prefer to have a shorter url (without having to use a service like tinyurl). – Amber Dec 19 '09 at 04:14
1

Common sense votes for `http://www.website.com/i123/item-name/' ... we have base for the ID and name if needed for storing or posting a link. the htm and ? links are a pain for the eye ;)

P.S. And for heavens sake html not htm!

Kornel Kisielewicz
  • 55,802
  • 15
  • 111
  • 149