ON-REV: Using Trevor's library on

Sarah Reichelt sarah.reichelt at gmail.com
Mon Jun 22 01:25:47 EDT 2009


On Mon, Jun 22, 2009 at 1:00 PM, stephen
barncard<stephenREVOLUTION2 at barncard.com> wrote:
> Sarah, you mentioned a few days ago that you successfully deployed Trevor's
> DB Library on your on-rev site.What did you do about the SETPROP   calls in
> there  (uLibDBObjectQuotes), as the on-rev vocabulary doesn't recognize such
> talk, and what else did you change?

Sorry, wasn't me, but hopefully whoever did it will chime in.

>
> Also what have people discovered about the use of variables in this
> environment?
> Script locals and constants appear to only last as long as the script is
> executing, then disappear. There doesn't seem to be any globals.  So far for
> persistent globals I've resorted to loading and unloading a text file that
> gets turned into an array every call, where I put everything.

I've seen some scripts that appear to use globals but I couldn't see
that is was really necessary. As you say, variables only seem to
persist while the script is running, although there is no problem
referring to the same variable in more than one <?rev ... ?> block.

I think for real persistent data, you need to store it either on the
server as a file, or on the user's computer as a cookie, depending on
the requirements. You have to remember that multiple people could be
accessing the web page at the same time, so the same data may not be
valid for all. Session variables are another possibility, but not one
I have explored yet.

Cheers,
Sarah



More information about the use-livecode mailing list