Text File | 1994-12-19 | 1018 b | 17 lines | [TEXT/ttxt]
CGI Demo by Chuck Shotton, cshotton@biap.com
This stack demonstrates how MacHTTP can pass arguments to HyperCard for processing. Specifically, this stack shows how to utilize the "CGI" (common gateway interface) AppleEvent sent by MacHTTP to applications. Edit the script of this stack and the "test_hc_form.html" file for more details.
Running the demo:
1. Place an alias to HyperCard 2.1 (or greater) in the same folder as MacHTTP. Name the alias "HyperCard.cgi" or "HyperCard.acgi".
2. Drag this stack over the HyperCard alias and drop it. HyperCard must be running the HyperCard CGI Demo stack, and it must be the frontmost window.
3. Run MacHTTP.
4. Access MacHTTP from your WWW client, using the URL:
http://your.address/test_hc_form.html
Helpful hints
• Use the path args (stuff after the "$" in a MacHTTP URL) to distinguish between multiple forms or searches, allowing HyperCard to handle multiple forms, etc.
• Take advantage of HyperCard's "item delimiters" property to make parsing form args easier.