Warning: This function has been deprecated. Use add_query_arg() instead.

wpmu_admin_redirect_add_updated_param() WordPress Function

This function allows you to add an updated parameter to the URL when an update is made from the WordPress administration area. This can be useful for tracking when a change is made from the admin area, or for displaying a message to the user after an update is made.

wpmu_admin_redirect_add_updated_param( string $url = '' ) #

Adds an ‘updated=true’ argument to a URL.


Description

Top ↑

See also


Top ↑

Parameters

$url

(string)(Optional) Redirect URL.

Default value: ''


Top ↑

Return

(string)


Top ↑

Source

File: wp-includes/ms-deprecated.php

function wpmu_admin_redirect_add_updated_param( $url = '' ) {
	_deprecated_function( __FUNCTION__, '3.3.0', 'add_query_arg()' );

	if ( strpos( $url, 'updated=true' ) === false ) {
		if ( strpos( $url, '?' ) === false )
			return $url . '?updated=true';
		else
			return $url . '&updated=true';
	}
	return $url;
}


Top ↑

Changelog

Changelog
VersionDescription
3.3.0Use add_query_arg()
MU (3.0.0)Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.