xmlrpc_removepostdata( string $content ): string

In this article

XMLRPC XML content without title and category elements.

Parameters

$contentstringrequired
XML-RPC XML Request content.

Return

string XMLRPC XML Request content without title and category elements.

Source

function xmlrpc_removepostdata( $content ) {
	$content = preg_replace( '/<title>(.+?)<\/title>/si', '', $content );
	$content = preg_replace( '/<category>(.+?)<\/category>/si', '', $content );
	$content = trim( $content );
	return $content;
}

Changelog

VersionDescription
0.71Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.