[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] Calling a program frame MacPerl





> I know I call an AppleScript and to a tell and X.EXE will run, but
> I have to hardcode the path and program name in. As I said the
> program name is unknown so this requires the user alter the Perl
> script by hand, not my first choice.

You can pass the program name to your CGI script via the URL like this:
http://web_server/macperl_script$script_argument.  Retrieve it with a
$app = $ENV{'PATH_INFO'} and use it as suggested below.

>MacPerl::DoAppleScript(<<END_SCRIPT);
>tell application "$app"
>   run like heck
>end
>END_SCRIPT

Erin