A Small Victory
Published 13 September 05 by Justin French, 16 comments
Nested URLs of any length
I’m not going to give away all the secrets just yet (there has to be some surprises left for the launch, right?), but the first thing I’ve done is removed the notion of categories from the URL. We only have Sections and Articles.
Then I added basic support for nested Sections, so the result is anything from /section/article-title through to /section/section/section/section/article-title.
It requires a few more queries to the database than I’d like to see, but if it becomes a problem, we can optimize later.
Date based URLs
For those who can’t let go of all that history, date based URLs are “in the bag”:
/section/YYYY/section/YYYY/MM/section/YYYY/MM/DD
I’ll also be experimenting a little more tonight to see if I can do the same with nested sections (/section/section/section/YYYY/MM/DD).
ID based URLs
For those who love the permanency of a numeric ID in the URL, /id will work fine.
And for those migrating from Textpattern’s clean URLs, I have good news. I’m 99% certain all these will work fine too:
/id/title/section/id/section/id/title
Much like Textpattern, I’m actually cheating here and ignoring both the section and title information — I’m just rendering an article matching the id.
Tags/Keywords
Of course, what would a modern web application be without tags? The kids love ‘em!
/tags/and/keywords/will list all your tags/tags/foo/and/keywords/foowill list all articles belonging to a tag
Default Section
An empty path (http://www.mysite.com/) will render the default section, as specified in your preferences.
All Together Now
Being able to set this as a site-wide preference would be fine, but I’m hoping I can step this up a notch.
How about the ability to set this on a per-section basis, so that a weblog or news archive can use date based URLs right alongside a catalogue using IDs and some marketing pages using /section/title? That’s the plan!
More?
If I’ve neglected a common URL structure you’d like to see in there, please leave a comment, and I’ll see what I can do.
Oh Yeah…
One last thing. I’d like to see some genuine hype and interest in TextThing. I want to know that the late nights are going to be worth it. I’m excited. TextDrive is excited. If you’re excited, please consider linking to this post to spread the good word, so that we can get other people excited.
I’d like to see the mailing list double or triple in size, and I’d like to see the referrals to this page go through the roof.