[REBOL] How does one persist data? Re:
From: cybarite:sympatico:ca at: 11-Oct-2000 5:37
For storing the post or get data, I added a key and a timestamp and stored
the name=value pairs on a file (%journal.txt). Then I could use the same
approach for fields whether they came from the journal for a previous post
or a new record from a user
write/append %journal.txt reduce [
When I wanted to look it up in another script,
requests: read/lines %journal.txt
Find the requests that matches the confirmation-number or other criteria
and instantiate a cgi object using the same approach:
selected-query-string: pick requests some-key ; some-key is used to pick
off one of the journal entries
data-record-object: make object! [ ;-- Default form values.
name-last: "No name entered"
name-first: "Not entered"
card-number: "Not entered"
special-instructions: "None entered"
customer-request: "None entered"
email: "None entered"
refer-to: "None specified"
record-object: make data-record-object decode-cgi-query
Now use the record-object data in your script such as record-object/status
Worked for me!