Passing variables to another script (was Re: ACGI form parsing in OSX?)
Passing variables to another script (was Re: ACGI form parsing in OSX?)
- Subject: Passing variables to another script (was Re: ACGI form parsing in OSX?)
- From: email@hidden
- Date: Mon, 4 Feb 2002 02:27:38 EST
Let me describe an actual project which uses this feature (and also
demonstrates OOP nicely).
1) Data is stored in text files. The data is wallpaper patterns and prices.
2) Via CGIs, the data in the text files can be remotely edited.
3) An Applescript application, "wallpaperDatabase", reads the text files
(currently about 500+ files, each with 100-200 "records") and builds an
internal data structure (currently 2.9 Meg of densely packed data). The
application has handlers to allow other scripts/applications to extract data
from it.
4) An acgi, "wallpaperestimate.acgi", calls handlers in wallpaperDatabase,
passing variables (values) so wallpaperDatabase knows what to look up. A
response is generated which wallpaperestimate.acgi can use to provide a price
quote back to the browser.
To see it in action, visit
http://www.fyhome.com/ecommerce/wallpaper/estimate.html
and enter whatever you want (make stuff up, it doesn't matter). The system
will sort out what it knows and what it doesn't. Compare the speed to other
database driven sites. Who says Applescript is slow?
Jeff Baumann
email@hidden
www.linkedresources.com
>
At 2/2/02 5:39 AM, email@hidden (email@hidden) Wrote:
>
>
> tell application "greet"
>
> set niceword to "hello"
>
> set responseIgot to greetwith(niceword)
>
> end tell
>
> display dialog responseIgot
>
>
>
> Got it now? : )
In a message dated 2/3/02 2:00:55 PM, Stephen Swift wrote:
>
Yes, but why would anyone need to use that? Pass variables from one script
>
to another that is.