WireArray::unshift() method

Unshift an element to the beginning of the WireArray (alias for prepend)

This is for consistency with PHP's naming convention of the array_unshift() method.

Usage

$wireArray->unshift($item);

Arguments

NameType(s)Description
itemWire, WireArray, mixed

Item to prepend.

Return value

$this

This instance.

See Also


WireArray methods and properties

API reference based on ProcessWire core version 3.0.236

“We chose ProcessWire because of its excellent architecture, modular extensibility and the internal API. The CMS offers the necessary flexibility and performance for such a complex website like superbude.de. ProcessWire offers options that are only available for larger systems, such as Drupal, and allows a much slimmer development process.” —xport communication GmbH