Deletes elements with specific IDs.
Description
See also
Parameters
- $element_ids
-
(array) (Required) Array of element IDs.
Source
File: src/db-objects/forms/form-edit-page-handler.php
private function delete_elements( $element_ids ) { $element_manager = $this->form_manager->get_child_manager( 'containers' )->get_child_manager( 'elements' ); foreach ( $element_ids as $element_id ) { $element = $element_manager->get( $element_id ); if ( ! $element ) { continue; } $element->delete(); } }
Changelog
Version | Description |
---|---|
1.0.0 | Introduced. |