Skip to main content

GV\Form_Collection

A collection of \GV\Form objects.

Source: stubs/gravityview.php:530

Details​

Methods​

MethodDescription
add()Add a \GV\Form to this collection.
get()Get a \GV\Form from this list.

Method Reference​

add()​

public function add( $form )

Add a \GV\Form to this collection.

Parameters​

NameTypeDefaultDescription
$form\GV\FormThe form to add to the internal array.

Returns​

  • void

Since: 2.0

Source: stubs/gravityview.php:541

get()​

public function get( $form_id, $backend='gravityforms' )

Get a \GV\Form from this list.

Parameters​

NameTypeDefaultDescription
$form_idintThe ID of the form to get.
$backendstring'gravityforms'The form backend identifier, allows for multiple form backends in the future. Unused until then.

Returns​

  • \GV\Form | null — The \GV\Form with the $form_id as the ID, or null if not found.

Since: 2.0

Source: stubs/gravityview.php:555