Inventory_Presser_Google_Maps_Widget::update( array $new_instance, array $old_instance )

Saves the widget settings when a dashboard user clicks the Save button.

On This Page


Parameters Parameters

$new_instance

(array) (Required)

$old_instance

(array) (Required)


Top ↑

Return Return

(array) The updated array full of settings


Top ↑

Source Source

File: includes/widget/class-widget-google-maps.php

	public function update( $new_instance, $old_instance ) {
		return array(
			'title'         => ( ! empty( $new_instance['title'] ) ) ? wp_strip_all_tags( $new_instance['title'] ) : '',
			'location_slug' => ( ! empty( $new_instance['location_slug'] ) ) ? $new_instance['location_slug'] : '',
		);
	}