I described this in the Post-installation Forum http://drupal.org/node/511826 and it was suggested that an issue here might be appropriate.
This was discovered while exploring another problem that may or may not be related, http://drupal.org/node/511144
Essentially, the problem is that while forums are like taxonomy terms and if you use the clean url http://example.com/taxonomy/term/xxx where xxx = forum number, you see a stream of teasers for the forum items just as you would see a stream of teasers for any other taxonomy term.
However, Taxonomy terms are not Forums. That is why it doesn't seem right when a url like http://example.com/forum/xxx where xxx = tid of a term that is not a forum or a container yields a display that mimics a forum topic listing and then includes a message that "The topic has been moved", when in fact the topic has not been moved and is in the forum where it was created.
This behaviour seems odd and it would be more appropriate if the user received an error message, like page not found, or not a forum.
I hope I have explained this well enough. Any thoughts on this would be appreciated. Thanks,
Izzy
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | taxonomy-term-mimics-forum-display-when-it-shouldn-t.patch | 883 bytes | Ainur |
| #3 | forum.patch | 806 bytes | Ainur |
Comments
Comment #1
michelleBumping the version. AFAIK, this behavior hasn't changed in D7 so it needs to be fixed there and backported. Something along the lines of this pseudo code:
Actually, checking if the tid is in the vid would probably get rid of the need for the newly added check if it's numeric.
Anyway, that needs more fleshing out, obviously, but that's the general idea. I'll probably figure out the exact code and add it to AF at some point. If I do, I'll post back the exact code to do it for D6 and then someone can port that to D7.
Michelle
Comment #2
Ainur commentedThis can get very messy, aseptically, if you are using pathauto module to generate aliases like forum/2009/10/13/page-title-or-nid. I have tons of duplicated pages in google index instead of 404 pages. Versions 5.x and 6.x are also affected.
This code, right after
$tid = (int)$tid;solved the problem for me, for Drupal 5.x version:we need
!empty($tid)check in order to keep our main forum page.Comment #3
Ainur commentedTested on Drupal 5.x, should work for 6.x also
Comment #4
Ainur commentedHere is patch for 7.x version based on 5.x and 6.x patches
Comment #6
andypostDuplicate of #74334: The URL /forum/x where x is a valid term id (tid) displays a category/term as a forum