Form::after_save( boolean|array $fields = false, array $args = array() )
Description #
Run all after save methods in fields and child fields.
Parameters #
- $fieldsboolean | array (Optional) Fields. Default value: false
- $argsarray (Optional) Arguments to be passed to method. Default value: array()
Source #
File: lib/class-form.php
public function after_save( $fields = false, $args = array() ) { // Delete session data. $this->delete_values_session(); if ( false === $this->prepared ) { $this->prepare(); } if ( false === $fields ) { $fields = $this->fields; } foreach ( (array) $fields as $field ) { $field->after_save( $args ); if ( ! empty( $field->child ) && ! empty( $field->child->fields ) ) { $this->after_save( $field->child->fields, $args ); } } }
Expand full source code Collapse full source code View on GitHub: lib/class-form.php:523
Add your comment