This is an old revision of the document!


Add form parameter

Synopsis

  param [--params <params>] <key> <value>

Examples

Issue an HTTP POST request

  params
  param mac ${net0/mac}
  param uuid ${uuid}
  param asset ${asset}
  chain http://boot.ipxe.org/demo/boot.php##params

Description

Add a form parameter with the specified key/value pair. If no form parameter list is specified, the default (unnamed) form parameter list will be used.

Command status

Success The form parameter was successfully added
Failure The form parameter was not successfully added

See also

Build options

This command is available only when the build option PARAM_CMD is enabled.

Notes

The most common use for form parameter lists is to generate HTTP POST requests. You can use a POST request to send large quantities of data to a web server by appending “##params” to the HTTP URI. For example, to send a complete PCI device listing to a web server:

  #!ipxe
  
  params
  :pciscan pciscan addr || goto pciscan_done
    param pcidev ${pci/${addr}.0.2}:${pci/${addr}.2.2}
    goto pciscan
  :pciscan_done
  chain http://192.168.0.1/boot/pcilist.php##params

You must create the form parameter list using the params command before attempting to create a form parameter using the param command.

cmd/param.1376950619.txt.gz · Last modified: 2013/08/19 22:16 by mcb30
Recent changes RSS feed CC Attribution-Share Alike 4.0 International Driven by DokuWiki
All uses of this content must include an attribution to the iPXE project and the URL https://ipxe.org
References to "iPXE" may not be altered or removed.