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

update


Description Description

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


Top ↑

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/class-widget-google-maps.php

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