|
|||||||||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||||||||||||||||||||||||||||||||
Try to make use of OpenACS Templating or http://your.openacs/doc/acs-templating/. If you can't avoid it try to isolate the HTML into a proc so editing the layout will be easier.
Using "if { $string == "foo" }" tries to make a numeric comparison first. Instead make use of "if { "foo" eq $string }" or if you need the negation "if {![string eq "foo" $string]}".
Since we are now using the query dispatcher it is encourage to make use of .xql files. If you use .xql files kindly delete the sql from the .tcl to avoid confusion. And place a "SQL" place holder on it. (ex. db_1row stmtname "SQL") to make it more readable.
This is the Tcl styleguide (PDF), try to apply relevant guidelines. In particular chapter 4,5 and 7.