Info
- 8 posts
- 3 voices
- Started 4 years ago by marky
- Latest reply from Michael Adams (mdawaffe)
- This topic is not resolved
Slugs and Duplicates
-
- Posted 4 years ago #
I've noticed when multiple topics share the same topic name, the slug gets modified a little strangely. For example, if I have four topics named "Test" the slugs would be:
- http://www.example.com/topic/test
- http://www.example.com/topic/test-1-2
- http://www.example.com/topic/test-1-2-3
- http://www.example.com/topic/test-1-2-3-4
- And so forth...
I'd imagine by the 50th topic, the URL would become quite unwieldy. Surely only the last slug number is necessary. Is there any way to fix this? Since these are supposed to be permalinks, it's somewhat urgent.
-
- Posted 4 years ago #
Did this happen during the upgrade? Or when making the topics?
-
- Posted 4 years ago #
During the upgrade. Admittedly, I haven't tried it when making new topics with duplicate names yet.
-
- Posted 4 years ago #
I think there is a problem with the upgrade script that causes this. There is no problem creating new topics.
You can manually edit the slugs in the database if you have this problem on a production site.
I'll raise a ticket about this though.
-
- Posted 4 years ago #
Ticket here:
-
- Posted 4 years ago #
Now fixed in Subversion repository.
-
- Posted 4 years ago #
Wonderful, thank you!
Is there a utility that will re-generate the slugs for me? Manually changing the database isn't really a viable option for me, I'm afraid. I have thousands of posts and no way of immediately knowing which were affected by this issue.
-
- Posted 4 years ago #
You can use the script attached to that ticket: http://trac.bbpress.org/ticket/671
It will only work once you upgrade to the next version of bbPress (it's not out yet :) ) or if you're running the "unstable" code in the repository.
Follow the instructions in the last comment.
-
You must log in to post.