On Tue, Nov 11, 2008 at 9:30 AM, Graham Fawcett <[EMAIL PROTECTED]> wrote: > > If you did choose to go the static-HTML route, then you could export a > "table of contents" in JavaScript, and let each page use this table to > determine which pages precede and follow it. So if you have pages > like: > > 2008-11-01.html > 2008-11-05.html > 2008-11-06.html > > you might have a toc.js file containing > > days = ['2008-11-01', '2008-11-05', '2008-11-06'] > function previous_day_url() { ... } // uses 'days' and > 'document.location.href' > function next_day_url() { ... } > > Each html file would include this JS file, and use it to power the > forward/backward buttons.
This is a nearly perfect description of how http://clojure-log.n01se.net/ currently works. The pages are generated via a Clojure program, then rsync'ed to the server where they're static. The JavaScript makes the forward and backward buttons skip days appropriately based on the directory listing. > You might learn some JavaScript, HTML and Elisp this way, but no Clojure. :-) So I do actually use Clojure to prepare the pages. At this point I could probably use ClojureScript instead of Clojure for the client-side code, but I haven't done that yet. --Chouser --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---