* * * * * Notes on a blog morgue I'm getting closer to getting the Boston Diaries public (for now, I'm using Apache's [1] mod_rewrite [2] to hide the fact that this still isn't an Apache module. One day … ) so I started work on getting the archive section to work. Obligatory Sidebar Links Hypertext, weblogs and journals [3] Reorg [4] And then a long digression about hypertext [5] Under Consruction [6] Tumblers tumbling [7] Tumbling through Code [8] Substance, Structure and Style [9] Still blogging along [10] Over fifteen million pages right here … [11] But it could be more … [12] The Electric Talmud anyone? [13] XML Pointers [14] Collapsing tumblers [15] the days … [16] It's tougher than I expected. I somewhat knew this the first time [17] I started talking about it (and ever since, see the Obligatory Sidebar Links). It's not really about the code, but about the design—how should I do it? The problem I have is one of extreme flexibility here—the code allows me to display an entire year, [18] an entire month, [19] as well as a day [20] and even arbitrary range of days. (Florida Ghost Hunters) [21] If a person selects the archive of a month, she should then get a list of days, plus maybe the titles of each entry—yet if she picks a large enough range of months (say, six months) then that might get too large. So then I'm thinking that if the number of days exceeds some threshhold (like, 60 days) then just list the months and days, and if it exceeds some larger threshhold (like 180 days) then just list the months. But then, if someone selects something like seven months, two full days and a half day, then what? Perhaps I should just give what was asked for. Perhaps. I identified thirteen specific cases to examine: Specification What I should return nothing specified years only? y list months y/m list days and entries y/m/d list entries y- list months y-y list months y-y/m list months y-y/m/d ? y/m- list months y/m-y/m list months y/m-y/m/d ? y/m/d- ? y/m/d-y/m/d ? [I should note that as I was doing the table, I originally had sixteen cases, but found out that three cases could not happen (which goes to show I don't even fully understand my own code) so I no longer have to worry about them.] Entries are automatically archived, and displaying an arbitrary range works fine now; I want the archive list to work automatically too. I should be able to add new entries and have the computer do everything else for me. After all, isn't that what a computer is for? [1] http://httpd.apache.org/ [2] http://httpd.apache.org/docs/mod/mod_rewrite.html [3] gopher://gopher.conman.org/0Phlog:1999/12/10.2 [4] gopher://gopher.conman.org/0Phlog:1999/12/11.2 [5] gopher://gopher.conman.org/0Phlog:1999/12/12.2 [6] gopher://gopher.conman.org/0Phlog:2000/02/04.4 [7] gopher://gopher.conman.org/0Phlog:2000/02/26.1 [8] gopher://gopher.conman.org/0Phlog:2000/03/13.1 [9] gopher://gopher.conman.org/0Phlog:2000/04/19.1 [10] gopher://gopher.conman.org/0Phlog:2000/08/07.2 [11] gopher://gopher.conman.org/0Phlog:2000/08/31.2 [12] gopher://gopher.conman.org/0Phlog:2000/08/31.3 [13] gopher://gopher.conman.org/0Phlog:2000/09/23.1 [14] gopher://gopher.conman.org/0Phlog:2001/02/11.1 [15] gopher://gopher.conman.org/0Phlog:2001/02/17.3 [16] gopher://gopher.conman.org/0Phlog:2001/03/09.1 [17] gopher://gopher.conman.org/0Phlog:1999/12/12.2 [18] gopher://gopher.conman.org/1Phlog:1999 [19] gopher://gopher.conman.org/1Phlog:2000/02 [20] gopher://gopher.conman.org/1Phlog:2000/02/04 [21] gopher://gopher.conman.org/0Phlog:2000/08/10.2-15.5 Email author at sean@conman.org