| Last modified: |
12/31/2002; 9:51:49 AM
|
| Something Else: |
C'mon. Be Creative.
|
|
|
Wednesday, June 19, 2002
Adding a date to your Radio archive pages. Day 8 of Mark Pilgrim's "30 days to a more accessible weblog": Constructing meaningful page titles. Mark writes:
"Every page of your weblog should have a unique and meaningful page title... Date-based archive pages should include the name of your weblog, followed by the date (or date range) for the page... "Unfortunately, I do not know how to customize page titles satisfactorily in Blogger or Radio. Radio has a <%longDate%> macro, but it can not be used as part of the page title..." It's true that longDate doesn't work in the template, but there is a way to do this. Here's how: 1. Edit your home page template. 2. Find the line (probably near the top) which reads: 3. Between <%title%> and , add the following macro: <%local (d); if radio.weblog.file.getArchiveFileDate (radioResponder.fileBeingRendered, @d) {": " + string.dateString (d)} else {""}%> Note: be careful if you copy and paste this code -- there should be no line-breaks. 4. Click the Submit button. The next time any of your archive pages are published, they'll have a date in their title. There's no need to stick with the default date format. You can format the date however you want -- Just replace the string.dateString (d) part with your own code. See the DocServer pages for the date and string verbs for some places to start digging. [Jake's Radio 'Blog]
< 8:00:43 AM >
|
|
| Archive: |
| June 2002 |
| Sun |
Mon |
Tue |
Wed |
Thu |
Fri |
Sat |
| |
|
|
|
|
|
1 |
| 2 |
3 |
4 |
5 |
6 |
7 |
8 |
| 9 |
10 |
11 |
12 |
13 |
14 |
15 |
| 16 |
17 |
18 |
19 |
20 |
21 |
22 |
| 23 |
24 |
25 |
26 |
27 |
28 |
29 |
| 30 |
|
|
|
|
|
|
| May Jul |
|
|