[typo] Redirects / and a themes question

Kevin Ballard kevin at sb.org
Fri Jul 29 14:17:55 EDT 2005

On Jul 29, 2005, at 11:09 AM, Scott Laird wrote:

>> and remove 'articles' so it looks like this:
>>   # allow neat perma urls
>>   map.connect ':year/:month/:day', :controller  =>  
>> 'articles', :action => 'find_by_date', :year => /\d{4}/, :day =>  
>> nil, :month => nil
>>   map.connect ':year/:month/:day/:title', :controller  =>  
>> 'articles', :action => 'permalink', :year => /\d{4}/
>> It's a terrible solution I know, but it's easier understanding how  
>> Typo works without any documentation, than to wade through the  
>> zillions of pages of tutorials for mod_rewrite, htaccess, and  
>> regex to figure it out.  I find that very impressive.
>> It's altering the core files, which I'm loathe to do.  But at  
>> least I can migrate my live site without worrying that SE visitors  
>> will hit 'Routing Error' pages instead of what they're looking for.
> You could also add a RedirectMatch line that redirects /200(.*) to / 
> articles/200$1

Of course, both of these solutions depend on TextPattern and Typo  
using the same algorithm to change a title into a permalink. The  
title "a post" shows up the same in both, but how does TextPattern  
deal with non-ascii characters? How would the permalinks compare with  
the following contrived title: "foo-bar 2.7 and Bob's $$ (money)" ?

Kevin Ballard
kevin at sb.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2378 bytes
Desc: not available
Url : http://rubyforge.org/pipermail/typo-list/attachments/20050729/0a1aed45/smime.bin

More information about the Typo-list mailing list