Alert: This function’s access is marked private. This means it is not intended for use by plugin or theme developers, only in other core functions. It is listed here for completeness.

wp_increase_content_media_count() WordPress Function

The wp_increase_content_media_count() function is used to increment the content media count for a given user. This is useful for tracking how much content a user has created or consumed.

wp_increase_content_media_count( int $amount = 1 ) #

Increases an internal content media count variable.


Parameters

$amount

(int)(Optional) Amount to increase by.

Default value: 1


Top ↑

Return

(int) The latest content media count, after the increase.


Top ↑

Source

File: wp-includes/media.php

function wp_increase_content_media_count( $amount = 1 ) {
	static $content_media_count = 0;

	$content_media_count += $amount;

	return $content_media_count;
}


Top ↑

Changelog

Changelog
VersionDescription
5.9.0Introduced.

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.

Show More
Show More