I tried all the ways and I can't make my variable persistent.

This piece of documentation is very unclear to me:

*Rivet aims to run standard Tcl code with as few surprises as possible.*
*At times this involves some compromises - in this case regarding the*
*global command. The problem is that the command will create truly*
*global variables. If the user is just cut'n'pasting some Tcl code into*
*Rivet, they most likely just want to be able to share the variable in*
*question with other procs, and don't really care if the variable is*
*actually persistant between pages. The solution we have created is to*
*create a proc ::request::global that takes the place of the global*
*command in Rivet templates. If you really need a true global variable,*
*use either ::global or add the :: namespace qualifier to variables you*
*wish to make global.*

Actually I'm having a lot of surprises, and I do indeed care about
variable persistence. What it means "to take place of the global
command" ? What is the "proc ::request::global" that "has been created"
? I have tried global and doesn't work. Tried prepending :: to my
variable, doesn't work. Tried using ::request::global, as well ::global,
nothing works.

In other words i want the behavior described as: That means that every
variable or procedure created in Tcl scripts resides by default in the
"::" namespace (just like in traditional Tcl scripting) and they are
persistent across different requests until explicitly unset or until the
interpreter is deleted.

Note I do not need per-session persistence. I need a true global
variable.

Thanks.
<i>Always striving to honor my word and commitments</i>

Reply via email to