IRA said:
> It's just this sort of problem that makes me wonder if the people
building aolserver ever actually USE aolserver to build web
> applications. It seems like not that big of a deal . . . until you
realize that we do this ALL THE TIME.
I could get as nasty and you and wonder why you are writing AOLserver apps
when you don't actualy know Tcl.
ns_puts "<a href=\"$link\">link</a>"
Can be written without the quotes simply by doing this:
ns_puts [subst {<a href="$link">link</a>}];# No escapes required!
Secondly:
<%
if ($condition) {
%>
This html
<%
} else {
%>
This other html
<%
}
%>
Makes for the most hideous, unreadable and unmaintainable code ever
concieved and should be avoided at all cost if you have any interest in
writing quality code.
Tcl is called a "procedural language", best to use it that way and create
loads of nice little procedure to create html. Surely,
set table_list [list 1 [link http://aol.com AOL]]
lappend table_list 2 [link http://genie.com Genie]
lappend table_list 3 [link http://msn.com MSN]
ns_puts [create_table -cols 2 -style linktable $table_list]
is a lot more elegant and maintainable than writing all the tags yourself?
(let alone using ASP style tags)
Just my $0.02...
Bas.
--
AOLserver - http://www.aolserver.com/
To Remove yourself from this list, simply send an email to <[EMAIL PROTECTED]> with the
body of "SIGNOFF AOLSERVER" in the email message. You can leave the Subject: field of
your email blank.