[bbDev] Custom permalinks patch
Michael D Adams
mikea at turbonet.com
Wed Mar 14 01:11:40 GMT 2007
On Mar 8, 2007, at 9:02 PM, Sam Bauers wrote:
> On 07/03/2007, at 6:25 PM, Michael D Adams wrote:
>
>> We can definitely add slug columns to topics and forums. They can
>> be populated with data that looks like sanitize_with_dashes
>> ( title ). We'll need to avoid making duplicates, of course :)
>
> OK then, a couple of questions...
>
> So we check if a slug exists already before inserting it into the
> table, or should we make topic/forum titles unique keys?
Why don't we make the slugs (not the title) UNIQUE for now. It's
easy to change to non-UNIQUE later (and hard to go the other way) if
there are compelling arguments to do so.
> If we allow duplicate names for topic/forum can we simply append
> the ID to the slug for the new duplicates?
It might be stylistically better to append an incrementing number:
cheese, cheese-2, cheese-3, ...
> Do we want to allow/handle UTF-8?
Yes. Let's try to do the same thing for slugs as we do for tag
urls. Of course, we need to figure out what's wrong with tag urls
first :) http://trac.bbpress.org/ticket/585
Michael
More information about the bbDev
mailing list