Re: AppleScript CGI
Re: AppleScript CGI
- Subject: Re: AppleScript CGI
- From: Graff <email@hidden>
- Date: Sun, 28 Dec 2003 15:42:09 -0500
You can change it to test.cgi after you save it. Just select it in the
Finder, get info on it (command-i), and change the text in the "Name &
Extension" section to from test.app or test.cgi.app to test.cgi and
then close the window.
Secondly, you can only use AppleScript CGU if you are using Mac OS X
Server. An AppleScript application needs to have events sent to it to
do its work and Apache doesn't do that. The version of Apache that
comes with Mac OS X Server has been modified so that it can send
events, there is an intermediate program that takes information from
the Apache program and sends events to your AppleScript application.
There is a workaround to do AppleScript CGI in the regular version of
Mac OS X. There is a 3rd party program which will act as a go-between
and will send events to your script so that it will work just like Mac
OS X Server. That program is "acgi dispatcher" and it works pretty
well. You can find it here:
<
http://www.sentman.com/acgi/index.php>
- Ken
On Dec 28, 2003, at 2:53 PM, Nelson Byrne wrote:
On web page
http://www.apple.com/applescript/guidebook/sbrt/pgs/sbrt.12.htm there
is an example of linking an AppleScript application to a web page.
I tried doing exactly what they said, but had two problems.
1) The page says to save the AS with name "test.cgi", location
"Sites", file format "application", Option Stay Open.
But that's not possible: when I try I get an error popup that says
"You cannot save this document with extension '.cgi' at the end of the
name. The required extension is '.app'. You can choose to use both, so
that your file name ends in '.cgi.app'."
I chose both. This caused another problem in that the HTML (copied
from the same page) calls for the name to be "test.cgi", so I changed
the HTML to point to "test.cgi.app".
When I access the HTML from Safari I see a cute little gadget with a
list that lets me pick one of a few colors. When I do so, though, I
get a page that says
"Method Not Allowed
The requested method POST is not allowed for the URL
/~xxx/test.cgi.app. (where xxx is my ID)
So what am I doing wrong?
OS 10.3.2
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.