[albatross-users] Form state problem

Dave Cole djc at object-craft.com.au
Wed Oct 30 14:04:13 EST 2002


> I feel ashamed to not have thought of that.  It's been several years
> since I've worked in an OO language, and the years of that "other p"
> have taken their toll I see.  I'll have to do some playing around to
> get the OrderInput class callable from the template, but that
> shouldn't be too much work.  The reason I set it from the template
> is I use a custom tag I wrote, alx-sql, to run SQL statements inside
> the template.  It works something like such...
> 
> <alx-sql stmt="SELECT field1, field2 FROM table1 WHERE field3 = %s"
> 	   args="(1,)">
> <!-- alx-sql sets the result in db_cursor and places it in ctx.locals
> space -->
> <al-for iter="row" expr="db_cursor.fetchall()">
> 
> Or also handy with <al-select name="choices"
> optionexpr="db_cursor.fetchall()" />

Very nice.  How hard was it building the extension tag?

- Dave

-- 
http://www.object-craft.com.au




More information about the Albatross-users mailing list