Make WordPress Core


Ignore:
Timestamp:
05/31/2015 04:53:12 PM (9 years ago)
Author:
johnbillion
Message:

Introduce featured_image, set_featured_image, remove_featured_image, and use_featured_image post type labels when registering a post type in order to override the 'Featured Image' text and its related phrases.

Props johnbillion, mordauk, valendesigns.
Fixes #19257.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/media.php

    r32609 r32673  
    23142314
    23152315    wp_embed_register_handler( 'youtube_embed_url', '#https?://(www.)?youtube\.com/embed/([^/]+)#i', 'wp_embed_handler_youtube' );
     2316    wp_embed_register_handler( 'youtube_v_url', '#https?://(www.)?youtube\.com/v/([^/]+)#i', 'wp_embed_handler_youtube' );
    23162317
    23172318    wp_embed_register_handler( 'googlevideo', '#http://video\.google\.([A-Za-z.]{2,5})/videoplay\?docid=([\d-]+)(.*?)#i', 'wp_embed_handler_googlevideo' );
     
    30093010    $hier = $post && is_post_type_hierarchical( $post->post_type );
    30103011
     3012    $post_type_object = get_post_type_object( $post->post_type );
     3013
    30113014    $strings = array(
    30123015        // Generic
     
    30673070
    30683071        // Featured Images
    3069         'setFeaturedImageTitle' => __( 'Set Featured Image' ),
    3070         'setFeaturedImage'    => __( 'Set featured image' ),
     3072        'setFeaturedImageTitle' => $post_type_object->labels->featured_image,
     3073        'setFeaturedImage'      => $post_type_object->labels->set_featured_image,
    30713074
    30723075        // Gallery
Note: See TracChangeset for help on using the changeset viewer.