Compound Parameters
Author=Steve%20Davenport
Some parameters, however, can be repeated in a request. In that case, the parameter names are differentiated by adding a period (.) after the parameter name and then a sequence number, as shown in the following example.
Item.1=1234& Item.2=2345
Other parameters can be repeated but, in addition, have associated parameters. These parameters extend the preceding example by adding another period and the associated parameter name, as shown in the following example.
Item.1.ASIN=3456789123& Item.1.Quantity=2
In this example, the item being added to a shopping cart has an identifier, the ASIN, and a quantity value. The equivalent expression in an XML document is, as shown in the following example.
<Item> <ASIN>3456789123</ASIN> <Quantity>2</Quantity> </Item>
The sequence number associates the identifier and its quantity value. The following example shows two compound parameters.
Item.1.ASIN=3456789123& Item.1.Quantity=2& Item.2.ASIN=123456& Item.2.Quantity=1
The sequence numbers associate the ASIN and quantity values. This means that the compound parameters can be written in a different order without causing a problem.
Item.1.ASIN=3456789123& Item.2.ASIN=123456& Item.1.Quantity=2& Item.2.Quantity=1