Description

Filter cvm_video_post_title allows you to modify post title for video imported with the plugin before the post is created.

Parameters

$post_title
(string)(required) The video title retrieved from Vimeo that will be used as post title

Default:None
$video_details
(array)(optional) The details of the video (video ID, title, description, etc.) retrieved from Vimeo

Default:None
$import_as_theme_post
(boolean)(optional) If the WP theme is compatible with the plugin and the user has selected to import video as theme post, this variable will be set to (boolean)true.

Default:False

Examples

Attach a few more words to the title if the length is less than 10 letters.

function append_to_title( $post_title ){
    $append = strlen( $post_title ) < 10 ? 'Vimeo video - ' : ''; 
    return $append . $post_title;
}
add_filter( 'cvm_video_post_title', 'append_to_title' );

Related