Re: XML-RPC with PHP and AppleScript
Re: XML-RPC with PHP and AppleScript
- Subject: Re: XML-RPC with PHP and AppleScript
- From: Jim Roepcke <email@hidden>
- Date: Mon, 7 Jan 2002 17:38:10 -0800
On Sunday, January 6, 2002, at 04:53 PM, Jesse Shanks wrote:
But, I am not getting the way to make a struct in the right record
format. I
feel like I have tried every possible way.
tell application "http://localhost/~username/server.php" to return call
xmlrpc {method name:"examples.getReviewNames", parameters:}
How would parameters look, if was sending a struct of string values? I
seem
to have had it work fine when it was a bunch of numbers. There is one
example (sorting demo) that requires:
an array of structs thus:
Dave 35
Edd 45
Fred 23
Barney 37
To send a single struct parameter, do this...
parameters:{{|Dave|:35, |Edd|:45, |Fred|:23, |Barney|:37}}
To send a string parameter then a struct parameter, do this:
parameters:{"hello", {|Dave|:35, |Edd|:45, |Fred|:23, |Barney|:37}}
Basically, parameters wants a list of arguments to send to the xmlrpc
method name. You should put the record's item names in |pipes| so that
the AppleEvent Manager (I assume) doesn't mangle them should the item
name be a reserved word or a word in a scripting dictionary/addition.
Jim