Qball's Weblog

Stuffkeeper, html export

Tags General  StuffKeeper 

I’ve implemented html output to stuffkeeper.

It parses a template files and generates html from it.

A template looks like this:

edit:

<html>
    <head>
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" >
        <title>
            StuffKeeper - {title}
        </title>
    </head>
    <body>
    [s
        <H3>{title}</H3>
        <table>
        [i
            <tr>
                <td align='right' valign='top'>
                    <b>{name}</b>
                </td>
                <td>
                    {field:string %
                    }{field:text <p>%</p>
                    }{field:link <a href='%'>%</a>
                    }{field:slider %/10
                    }{field:integer %
                    }{field:boolean %
                    }{field:image <img src='%' />
                    }{field:list <div id='list'>
                       }{field:list <i>%</i><BR />
                    }{field:list </div>}
                </td>
            <tr>
        ]
        </table>
    ]
    </body>
</html>

This generates this code: click here. (yes it needs css)

Or an more advanced example