.

 

Code Features

Nice things about Ftrain that you may never have noticed before.

The Ftrain code, mostly by accident, has these exciting features:

  1. Allows for the creation of highly structured, linked narratives in fairly simple XML. Writing text for Web publication is easy for those who know HTML and the basic rules of XML.
  2. Organizes these narratives chronologically, automatically producing “most recent” views, as well as organizing things into larger, structured, multi-level narratives.
  3. Creates a pretty calendar.
  4. Has an, uh, integrated linking system that works nicely with your browser. If you see something you like, you click a button and a Javascript bookmarklet puts the right variables into a form; you then add a category and a description and it logs the link to an XML file. XSLT then sorts links by category and chronology, etc.
  5. Entirely written in vanilla XSLT sans extensions - the link CGI, and one command-line function that generates random numbers both require a little perl, but other than that it's clean as a whistle. It runs fine with SAXON and LibXSLT. XSLT is a fairly simple language and I've programmed everything by the book, using a functional rather than imperative style whenever possible (although I could do better). Nothing would stop it from running on Windows (it was developed on Linux).
  6. Produces totally vanilla HTML - nothing need be done on the server, although if you wanted to spit out PHP code from the XSLT for comment systems, or link things back to style sheets and the like, nothing is stopping you. If you run the XSL processor locally and then use rsync to copy the files, even with few hundred files you can usually upload all your changes in about a minute.
  7. On a 400 Mhz processor it takes 44 seconds to completely process 2.5 megs of nested XML, producing 725 or so linked files. Without the links, calendar, and random functions this is about 10-14 seconds. Thus you could churn the thing every ten minutes or hour with no harm done.


[Top]

Ftrain.com

PEEK

Ftrain.com is the website of Paul Ford and his pseudonyms.

There is a Facebook group.

And six-words-only Twitter posts.

See also: Gary Benchley, Rock Star, a novel; Harper's Magazine; NPR's All Things Considered; The Morning News.

POKE


Syndicate: RSS1.0, RSS2.0
Links: RSS1.0, RSS2.0

Contact

© 1974-2007 Paul Ford

Recent

I never told you because I was kind of out of it for a while there but. (April 1)

Sasquatch. (March 26)

Over There. (March 24)

Signs. (March 21)

Eloquence Personified. (March 20)

Note. I wonder what the poor folks are doing tonight. (March 20)

The Wind Chest, by Paul Ford. (March 18)

Six-Word Reviews of 763 SXSW Mp3s. (March 13)

This Is Just To Say. (March 3)

Clouds. (February 27)

Fishing Party. (February 10)

A Joke. (February 5)

The Vet, by Paul Ford. (February 4)

The Swings. (January 31)

Tag Cloud, by Paul Ford. (January 30)

Another Veil-lifter Pitched, by Paul Ford. (January 29)

Saturday, by Paul Ford. (January 28)

Love Explosion. (November 2)

$5 Chocolate Bar. (October 1)

Big O. (September 23)

More...
Tables of Contents