tcl-websh-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dav...@dedasys.com (David N. Welton)
Subject putx of empty string before first brace does not send headers
Date Wed, 26 Dec 2001 16:16:54 GMT

test putx-3.7 {putx of empty string before first brace does not send headers} {
    web::response -select #buf-putx-37
    web::config putxmarkup tag
    set res [web::putx {<?web::response -sendheader 0?>}]
    web::config putxmarkup brace
    set ::buf-putx-37
} {}

I have some reservations about this.

Positives: 
        Makes it possible to fool around with the headers.

Negatives:
        Requires coding around things in the parser.

        Arbitrary - including even a " " will make it not work
        correctly.  This might confuse people.

I avoided this in mod_dtcl by buffering the first bit of non-Tcl, so
that instead of having to make sure there is no space, you can
manipulate headers in the first chunk of Tcl code (or you can set up
buffering there so that you can manipulate headers wherever you want).

-- 
David N. Welton
   Consulting: http://www.dedasys.com/
Free Software: http://people.debian.org/~davidw/
   Apache Tcl: http://tcl.apache.org/
     Personal: http://www.efn.org/~davidw/

Mime
View raw message