Forum Moderators: phranque

Message Too Old, No Replies

Should I put thread titles in the url of each page on a forum?

Or is it best to just use numbers for forum thread URLs?

         

roldar

1:31 am on Jun 16, 2005 (gmt 0)

10+ Year Member



I'm working on a forum and am changing it from parameter-based URLs to static looking ones using mod-rewrite.

Each forum entry will have a unique ID, a title, and the message itself. Is there any reason not to use the title of the message in the URL? It seems like this would help out where SEO is concerned.

Each title would of course have to be mangled a bit in order for it to work (replace spaces with hyphens, remove apostrophes and quotes completely, etc.) but I can't see any reason why I shouldn't. Rather than a single parameter with the ID number, however, the URL would have to contain the ID number as well as the title in the case that there were two posts with the same title.

I picture it looking like:
www.example.com/12345/thread-title-here/

The 12345 would be the ID #.

My only concern at this point is the potential for very long URLs. Do search engines get bored after the first 100 chracters of a URL? I could of course crop the longer titles down to 20-30 characters, but I'd rather not unless there's a reason to.

----------

On a second slightly different topic, is there any reason why I should mod-rewrite my URLs to .html (or .php, or any other extention) rather than making each forum entry appear as its own folder?

I see WW uses .html, but I'm considering using www.example.com/12345/thread-title-here/replies-here/ so that each reply to the original thread appears to be a subfolder of the original thread.

-----------

So it boils down to:

1) Should I include the title in the URL for each thread in a forum?

2) Are loooooooong URLs penalized in SERPs or at risk of upsetting spiders?

3) Is there any compelling reason to use extensions in URLs? I prefer folders myself, but maybe there's a reason why WW uses .html.

roldar

1:37 am on Jun 16, 2005 (gmt 0)

10+ Year Member



One more thing I just thought of. Maybe it would be best to append the ID # to the end of the title in the URL?

It might confuse spiders if I had www.example.com/12345/thread-title-here/ because they would not understand the hierarchy of the site (that all threads are brothers, rather than distant relatives due to the fact that they all appear to be subfolders of a unique folder - the ID #).

So maybe www.example.com/forum1/thread-title-here_12345/ would be best? I would use the underscore before the ID# because I've been told that search engines treat hyphens as spaces (i.e. they understand "thread-title-here" as "thread title here") and underscores as periods.

Any advice is greatly appreciated.

bennymack

3:19 pm on Jun 16, 2005 (gmt 0)

10+ Year Member



This topic is of interest to me as well. I posted about it here:
[webmasterworld.com...]

I would also like to know the answer to this one. Will you be doing all this strictly with mod-rewrite? It seems like this is a little bit more in-depth than what people normally do with mod-rewrite. I'd be interested to see what your rules look like when you're done (if you go ahead and do it).

Also, have you thought about obtaining a stop work list and stripping them out of the URLs and only leaving SE relevant terms in the URLs? And perhaps limiting them to, say, 3 or 4 of the non-stopword terms?

roldar

4:30 am on Jun 17, 2005 (gmt 0)

10+ Year Member



Will you be doing all this strictly with mod-rewrite? It seems like this is a little bit more in-depth than what people normally do with mod-rewrite.

Mod-rewrite + mysql/asp (not my choice, but since the project is on an IIS server and the rest of the site is written using in the language, I'm going to dust off my asp skills).

I'd be interested to see what your rules look like when you're done (if you go ahead and do it).

I'm not sure which way I'm going to end up organizing things, but I'm on the fence between

1) no title in the URL at all
2) title + "_threadID".

The first option is relatively simple.

The second option is a little more complicated. I'm not 100% certain how to include hypens in a regex, but my guess is that the rewrite would look something like this:

RewriteRule ^([a-Z]+)/([a-Z0-9-]+)_([0-9]+)/$ ht*p://www.example.com/forum_redirect.php?forumname=$1&title=$2&id=$3 [L]

Also, have you thought about obtaining a stop work list and stripping them out of the URLs and only leaving SE relevant terms in the URLs? And perhaps limiting them to, say, 3 or 4 of the non-stopword terms?

That's an interesting idea and I hadn't really considered doing it. To be honest, the SEO aspect is really not the highest on this particular project, but I figured I may as well do it right if I was going to do it at all.

The site is more for internal communication of an organization, but since they don't have reason to hide any of their communications they'd just as soon let the search engines pick up everything.

I like the idea that people could figure out what a thread in the forum is about merely by looking at its URL.