Action: OutputFromId

Purpose: Outputs a sub-tree of a specified DOM, starting from the Element with the specified id attribute.

Note: This Action was introduced in Build 3.

Action-specific name/value pairs:

Parameter Name Description
id The value of the id attribute whose owner Element will be at the top of the DOM sub-tree that is outputted.
DocumentName or DocumentOID The Name or OID of the document containing the sub-tree

Example Request

&MDBAccessKeyId=[your access key id]
&Signature=[computed signature]

Example Response


<foo id="theid" location="Drumcondra">
   <bar name="Cat and Cage">
      pub 1
   <bar name="Fagan's" owner="John" tied="true">
      pub 2
   <offlicense name="oddbins" />
   <bar name="Gravedigger's">
      pub 3
   <bar name="Ivy House">
      pub 4

Note that only the tags in the sub-tree will be output. M/DB:X will not add any other tags or wrappers to the output.

JSON (ie if OutputFormat=JSON specified in the Request)

{foo:{id:"theid",location:"Drumcondra",bar:[{name:"Cat and Cage",#text:"pub 1"},
 {name:"Fagan's",owner:"John",tied:"true",#text:"pub 2"},
 {name:"Gravedigger's",#text:"pub 3"},{name:"Ivy House",#text:"pub 4"}],

M/DB:X uses the following rules for converting XML to JSON: