Make WordPress Core


Ignore:
Timestamp:
07/11/2008 03:59:14 PM (17 years ago)
Author:
ryan
Message:

Rename wp_caption shortcode to caption. Allow themes to disable captioning. Use dashes instead of underscores in class names. Props azaozz. see #6812

File:
1 edited

Legend:

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

    r8289 r8313  
    352352
    353353add_shortcode('wp_caption', 'img_caption_shortcode');
     354add_shortcode('caption', 'img_caption_shortcode');
    354355
    355356function img_caption_shortcode($attr, $content = null) {
    356    
     357
     358    if ( defined('CAPTIONS_OFF') && true == CAPTIONS_OFF )
     359        return $content;
     360
    357361    // Allow plugins/themes to override the default caption template.
    358362    $output = apply_filters('img_caption_shortcode', '', $attr, $content);
Note: See TracChangeset for help on using the changeset viewer.