The easy way is not so obvious:
Looks easy, and it's easy to work with. It may not be completely obvious what it's doing, however. To clarify it, let's look at a closer-to-real implementation of the script:
This is actually the script template I use to create table renderers. (I've included it in this page for your convenience.) I copy it into the #tools table, rename it to, for example, RenderTableAsEvent, and change every occurance of XXXX to Event. The script is then complete and fully functional.
This script inserts the address of the table to be rendered (tableAdr) into the page table so that the table's entries are visible to the website framework scripts--and to templates. It then gets a custom template (used solely by this renderer), calls html.runDirectives() to extract any directives embedded in the template, calls html.processMacros() to expand all macros in the template, and returns the result to the caller. The caller turns out to be html.tenderRender, which substitutes the returned result into the page template as the bodytext.
To use this script, you need a corresponding template in the #templates table. It can be a string, outline, or wptext.
The template for the RenderTableAsEvent table renderer would be named--reasonably enough, I think--Event, and might look like this:
Notice that this renderer template does not contain any of the page framing macros you're accustomed to seeing in website templates. This template only applies to the page content. It describes the formatting of what will become just the bodytext in the page template. So you don't have to worry about page headers, page footers, and such.
You thought that was easy? There's an even easier way!
 |
 |
 |
 |
This page is a Fat Page. It includes script(s) encoded by and for Frontier. To retrieve the script(s), save the page as source text and open it using the File->Open command.
|
 |
 |
Page 1: What Is A Table Renderer
Page 2: Anatomy of a Table Renderer
Page 3: The Hard Way
Page 4: The Easy Way
Page 5: The Easiest Way
Page 6: About the Author