Plugin Directory

Changeset 1256717


Ignore:
Timestamp:
09/30/2015 04:28:13 PM (11 years ago)
Author:
fourlightsweb
Message:

Changing text domain from a variable to strings

Location:
wp-gallery-custom-links/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • wp-gallery-custom-links/trunk/readme.txt

    r1256708 r1256717  
    55Requires at least: 3.3.1
    66Tested up to: 4.3.1
    7 Stable tag: 1.10.4
     7Stable tag: 1.10.5
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    148148== Changelog ==
    149149
     150= 1.10.5 =
     151* Changed translation text domain from a variable to strings, because apparently a variable doesn't universally work no matter how smart it makes me feel.
     152
    150153= 1.10.4 =
    151154* Updated some text domain settings to be in accordance with the translate.wordpress.org translation system.
     
    261264== Upgrade Notice ==
    262265
     266= 1.10.5 =
     267* Changed translation text domain from a variable to strings, because apparently a variable doesn't universally work no matter how smart it makes me feel.
     268
    263269= 1.10.4 =
    264270* Updated some text domain settings to be in accordance with the translate.wordpress.org translation system.
  • wp-gallery-custom-links/trunk/wp-gallery-custom-links.php

    r1256708 r1256717  
    55Text Domain: wp-gallery-custom-links
    66Description: Specify custom links for WordPress gallery images (instead of attachment or file only).
    7 Version: 1.10.4
     7Version: 1.10.5
    88Author: Four Lights Web Development
    99Author URI: http://www.fourlightsweb.com
     
    4444    //          return "filter" $output with replaced links to original $GLOBALS['shortcode_tags']['gallery'] call
    4545    private static $first_call = true;
    46     private static $textdomain_id = 'wp-gallery-custom-links';
    4746    private static $class_name = 'WPGalleryCustomLinks';
    4847   
     
    6160       
    6261        // Load translations
    63         load_plugin_textdomain( self::$textdomain_id, false, basename( dirname( __FILE__ ) ) . '/languages' );
     62        load_plugin_textdomain( 'wp-gallery-custom-links', false, basename( dirname( __FILE__ ) ) . '/languages' );
    6463    } // End function init()
    6564
    6665    public static function loadPluginTextDomain() {
    6766        // The codex says this is needed to load plugin language files
    68         load_plugin_textdomain( self::$textdomain_id, false, basename( dirname( __FILE__ ) ) . '/languages' );
     67        load_plugin_textdomain( 'wp-gallery-custom-links', false, basename( dirname( __FILE__ ) ) . '/languages' );
    6968    }
    7069   
     
    8483        // Gallery Link URL field
    8584        $form_fields['gallery_link_url'] = array(
    86             'label' => __( 'Gallery Link URL', self::$textdomain_id ) .
     85            'label' => __( 'Gallery Link URL', 'wp-gallery-custom-links' ) .
    8786                ' <a href="#" onclick="jQuery(\'.wpgcl_gallery_link_help\').hide();jQuery(\'#wpgcl_gallery_link_url_help\').show(); return false;" onblur="jQuery(\'#wpgcl_gallery_link_url_help\').hide();">[?]</a>' .
    8887                '<div id="wpgcl_gallery_link_url_help" style="'.$help_css.'" class="wpgcl_gallery_link_help">' .
    89                 __( 'Will replace "Image File" or "Attachment Page" link for this image in galleries. Use [none] to remove the link from this image in galleries.', self::$textdomain_id ) .
     88                __( 'Will replace "Image File" or "Attachment Page" link for this image in galleries. Use [none] to remove the link from this image in galleries.', 'wp-gallery-custom-links' ) .
    9089                ' <a href="#" onclick="jQuery(\'#wpgcl_gallery_link_url_help\').hide(); return false;">[X]</a>' .
    9190                '</div>',
     
    9695        $target_value = get_post_meta( $post->ID, '_gallery_link_target', true );
    9796        $form_fields['gallery_link_target'] = array(
    98             'label' => __( 'Gallery Link Target', self::$textdomain_id ) .
     97            'label' => __( 'Gallery Link Target', 'wp-gallery-custom-links' ) .
    9998                ' <a href="#" onclick="jQuery(\'.wpgcl_gallery_link_help\').hide();jQuery(\'#wpgcl_gallery_link_target_help\').show(); return false;" onblur="jQuery(\'#wpgcl_gallery_link_target_help\').hide();">[?]</a>' .
    10099                '<div id="wpgcl_gallery_link_target_help" style="'.$help_css.'" class="wpgcl_gallery_link_help">' .
    101                 __( 'This setting will be applied to this image in galleries regardless of whether or not a Gallery Link URL has been specified.', self::$textdomain_id ) .
     100                __( 'This setting will be applied to this image in galleries regardless of whether or not a Gallery Link URL has been specified.', 'wp-gallery-custom-links' ) .
    102101                ' <a href="#" onclick="jQuery(\'#wpgcl_gallery_link_target_help\').hide(); return false;">[X]</a>' .
    103102                '</div>',
     
    105104            'html'  => '
    106105                <select name="attachments['.$post->ID.'][gallery_link_target]" id="attachments['.$post->ID.'][gallery_link_target]">
    107                     <option value="">'.__( 'Do Not Change', self::$textdomain_id ).'</option>
    108                     <option value="_self"'.($target_value == '_self' ? ' selected="selected"' : '').'>'.__( 'Same Window', self::$textdomain_id ).'</option>
    109                     <option value="_blank"'.($target_value == '_blank' ? ' selected="selected"' : '').'>'.__( 'New Window', self::$textdomain_id ).'</option>
     106                    <option value="">'.__( 'Do Not Change', 'wp-gallery-custom-links' ).'</option>
     107                    <option value="_self"'.($target_value == '_self' ? ' selected="selected"' : '').'>'.__( 'Same Window', 'wp-gallery-custom-links' ).'</option>
     108                    <option value="_blank"'.($target_value == '_blank' ? ' selected="selected"' : '').'>'.__( 'New Window', 'wp-gallery-custom-links' ).'</option>
    110109                </select>'
    111110        );
     
    113112        $preserve_click_value = get_post_meta( $post->ID, '_gallery_link_preserve_click', true );
    114113        $form_fields['gallery_link_preserve_click'] = array(
    115             'label' => __( 'Gallery Link OnClick Effect', self::$textdomain_id ) .
     114            'label' => __( 'Gallery Link OnClick Effect', 'wp-gallery-custom-links' ) .
    116115                ' <a href="#" onclick="jQuery(\'.wpgcl_gallery_link_help\').hide();jQuery(\'#wpgcl_gallery_link_preserve_click_help\').show(); return false;" onblur="jQuery(\'#wpgcl_gallery_link_preserve_click_help\').hide();">[?]</a>' .
    117116                '<div id="wpgcl_gallery_link_preserve_click_help" style="'.$help_css.'" class="wpgcl_gallery_link_help">' .
    118                 __( 'Lightbox and other OnClick events are removed by default from this image in galleries. This setting will only be applied to this image in galleries if this image has a Gallery Link URL specified.', self::$textdomain_id ) .
     117                __( 'Lightbox and other OnClick events are removed by default from this image in galleries. This setting will only be applied to this image in galleries if this image has a Gallery Link URL specified.', 'wp-gallery-custom-links' ) .
    119118                ' <a href="#" onclick="jQuery(\'#wpgcl_gallery_link_preserve_click_help\').hide(); return false;">[X]</a>' .
    120119                '</div>',
     
    122121            'html'  => '
    123122                <select name="attachments['.$post->ID.'][gallery_link_preserve_click]" id="attachments['.$post->ID.'][gallery_link_preserve_click]">
    124                     <option value="remove">'.__( 'Remove', self::$textdomain_id ).'</option>
    125                     <option value="preserve"'.($preserve_click_value == 'preserve' ? ' selected="selected"' : '').'>'.__( 'Keep', self::$textdomain_id ).'</option>
     123                    <option value="remove">'.__( 'Remove', 'wp-gallery-custom-links' ).'</option>
     124                    <option value="preserve"'.($preserve_click_value == 'preserve' ? ' selected="selected"' : '').'>'.__( 'Keep', 'wp-gallery-custom-links' ).'</option>
    126125                </select>'
    127126        );
    128127        // Gallery Link additional css classes field
    129128        $form_fields['gallery_link_additional_css_classes'] = array(
    130             'label' => __( 'Gallery Link Additional CSS Classes', self::$textdomain_id ) .
     129            'label' => __( 'Gallery Link Additional CSS Classes', 'wp-gallery-custom-links' ) .
    131130                ' <a href="#" onclick="jQuery(\'.wpgcl_gallery_link_help\').hide();jQuery(\'#wpgcl_gallery_link_additional_css_classes_help\').show(); return false;" onblur="jQuery(\'#wpgcl_gallery_link_additional_css_classes_help\').hide();">[?]</a>' .
    132131                '<div id="wpgcl_gallery_link_additional_css_classes_help" style="'.$help_css.'" class="wpgcl_gallery_link_help">' .
    133                 __( 'Additional CSS classes specified here will be applied to the <strong><em>link</em></strong> around this image in galleries regardless of whether or not a Gallery Link URL has been specified.', self::$textdomain_id ) .
     132                __( 'Additional CSS classes specified here will be applied to the <strong><em>link</em></strong> around this image in galleries regardless of whether or not a Gallery Link URL has been specified.', 'wp-gallery-custom-links' ) .
    134133                ' <a href="#" onclick="jQuery(\'#wpgcl_gallery_link_additional_css_classes_help\').hide(); return false;">[X]</a>' .
    135134                '</div>',
Note: See TracChangeset for help on using the changeset viewer.