Index: openacs-4/packages/xml-rpc/www/doc/index.html =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xml-rpc/www/doc/index.html,v diff -u -r1.5 -r1.5.2.1 --- openacs-4/packages/xml-rpc/www/doc/index.html 9 May 2019 09:18:34 -0000 1.5 +++ openacs-4/packages/xml-rpc/www/doc/index.html 6 May 2021 18:51:49 -0000 1.5.2.1 @@ -49,7 +49,7 @@

The server is installed by default at /RPC2/. Administrators can change this by unmounting the package and remounting it at the desired URL. The -server can be disabled or enabled via the /admin pages. +server can be disabled or enabled via the /admin pages.

@@ -76,7 +76,7 @@

  • They need to be able to accept arguments as sent to them from xmlrpc::decode - +

    In XML-RPC, every value has a datatype. Since TCL is a weakly-typed language, we could care less about the datatype (for the most part). So @@ -88,7 +88,7 @@ TCL arrays and XML-RPC arrays are sent as TCL lists. For example, if your proc expects a struct with 3 members (name, address and phone), then this is how the beginning of your proc will look. - +

       array set user_info $struct
       set name $user_info(name)
    @@ -98,16 +98,16 @@
     
       Or if your proc expects an array with n integers, which it then sums,
       then this is how your proc will look.
    -    
    +
       
       foreach num $array {
           incr sum $num
       }
       
    - +

  • - +
  • They need to be able to return data that xmlrpc::respond will be able to translate to XML. @@ -149,12 +149,12 @@
  • Returning an array of structs
    -    set user1(name) {-string "George Bush"} 
    +    set user1(name) {-string "George Bush"}
         set user1(id) {-int 41}
    -    set user2(name) {-string "Bill Clinton"} 
    +    set user2(name) {-string "Bill Clinton"}
         set user2(id) {-int 42}
    -    return [list -array [list 
    -                             [list -struct [array get user1]] 
    +    return [list -array [list
    +                             [list -struct [array get user1]]
                                  [list -struct [array get user2]]]]
         
  • @@ -223,7 +223,7 @@ This package also implements a simple XML-RPC client. Any package that needs to make XML-RPC calls can simply add a dependency to this package and then call xmlrpc::remote_call. As an example, the -system.add method sums a variable number of ints. To call the +system.add method sums a variable number of ints. To call the system.add method on http://example.com/RPC2/, do this:
     catch {xmlrpc::remote_call http://example.com/RPC2/ system.add -int 4 -int 44 -int 23} result
    @@ -257,11 +257,11 @@
     The first implementation of XML-RPC for AOLServer was ns_xmlrpc, whose credits
     state:
     
    - Ns_xml conversion by Dave Bauer (dave at thedesignexperience.org) with - help from Jerry Asher (jerry at theashergroup.com). This code is based - on the original Tcl-RPC by Steve Ball with contributions by Aaron - Swartz. The original Tcl-RPC uses TclXML and TclDOM to parse the - XML. It works fine but since OpenACS-4 will use ns_xml I converted it. + Ns_xml conversion by Dave Bauer (dave at thedesignexperience.org) with + help from Jerry Asher (jerry at theashergroup.com). This code is based + on the original Tcl-RPC by Steve Ball with contributions by Aaron + Swartz. The original Tcl-RPC uses TclXML and TclDOM to parse the + XML. It works fine but since OpenACS-4 will use ns_xml I converted it.