Filters

Description

rtmedia_can_user_tag_photo


Filter is use to allow / disallow photo tagging. Add the following code in your theme’s functions.php file to disallow all users to tag each other into media.

add_filter('rtmedia_can_user_tag_photo', 'rtmedia_filter_can_user_tag_photo', 10, 2);

function rtmedia_filter_can_user_tag_photo($allow, $media_id){

    $allow = FALSE;
    return $allow;
}

rtmedia_tag_photo_button_text

/**
 * This callback changes the `Tag Photo` button text.
 *
 * @param string $button_text Holds the button text string.
 * @return string $button_text
 */
function rtmedia_tag_photo_button_text_callback( $button_text ) {
	$button_text = __( 'Tag photo custom button text goes here...', 'rtmedia' );

	return $button_text;
}

add_filter( 'rtmedia_tag_photo_button_text', 'rtmedia_tag_photo_button_text_callback' );

rtmedia_tag_photo_complete_button_text

/**
 * This callback changes the `Done Tagging` button text.
 *
 * @param string $button_text Holds the button text string.
 * @return string $button_text
 */
function rtmedia_tag_photo_complete_button_text_callback( $button_text ) {
	$button_text = __( 'Done tagging custom button text goes here...', 'rtmedia' );

	return $button_text;
}

add_filter( 'rtmedia_tag_photo_complete_button_text', 'rtmedia_tag_photo_complete_button_text_callback' );