Changeset 1581815
- Timestamp:
- 01/25/2017 11:11:10 AM (9 years ago)
- Location:
- polylang-theme-strings
- Files:
-
- 10 added
- 2 edited
-
tags/3.3.2 (added)
-
tags/3.3.2/css (added)
-
tags/3.3.2/css/admin.css (added)
-
tags/3.3.2/css/index.php (added)
-
tags/3.3.2/index.php (added)
-
tags/3.3.2/js (added)
-
tags/3.3.2/js/admin.js (added)
-
tags/3.3.2/js/index.php (added)
-
tags/3.3.2/mw-polylang-theme-strings.php (added)
-
tags/3.3.2/readme.txt (added)
-
trunk/mw-polylang-theme-strings.php (modified) (6 diffs)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
polylang-theme-strings/trunk/mw-polylang-theme-strings.php
r1580873 r1581815 5 5 Plugin URI: http://modeewine.com/en-polylang-theme-strings 6 6 Description: Automatic scanning of strings translation in the theme and registration of them in Polylang plugin. Extension for Polylang plugin. 7 Version: 3.3. 17 Version: 3.3.2 8 8 Author: Modeewine 9 9 Author URI: http://modeewine.com … … 16 16 { 17 17 static $prefix = 'mw_polylang_strings_'; 18 static $plugin_version = '3.3. 1';18 static $plugin_version = '3.3.2'; 19 19 static $pll_f = 'pll_register_string'; 20 20 private $paths; … … 92 92 if (!pll_default_language()) 93 93 { 94 wp_redirect(admin_url('options-general.php?page=mlang')); 94 if (defined('POLYLANG_VERSION') && (float)POLYLANG_VERSION < 2.1) 95 { 96 wp_redirect(admin_url('options-general.php?page=mlang')); 97 } 98 else // for Polylang >= 2.1 99 { 100 wp_redirect(admin_url('admin.php?page=mlang')); 101 } 102 95 103 exit; 96 104 } … … 118 126 { 119 127 window.<?php echo self::$prefix; ?>admin.attr.prefix = '<?php echo self::$prefix; ?>'; 120 window.<?php echo self::$prefix; ?>admin.attr.urls['polylang_strings'] = '<?php echo admin_url('options-general.php?page=mlang&tab=strings'); ?>'; 121 window.<?php echo self::$prefix; ?>admin.attr.urls['polylang_strings_theme_current'] = '<?php echo admin_url('options-general.php?page=mlang&tab=strings&s&group=' . __('Theme') . ': ' . wp_get_theme()->Name . '&paged=1'); ?>'; 128 129 <?php 130 131 if (defined('POLYLANG_VERSION') && (float)POLYLANG_VERSION < 2.1) 132 { 133 ?> 134 window.<?php echo self::$prefix; ?>admin.attr.urls['polylang_strings'] = '<?php echo admin_url('options-general.php?page=mlang&tab=strings'); ?>'; 135 window.<?php echo self::$prefix; ?>admin.attr.urls['polylang_strings_theme_current'] = '<?php echo admin_url('options-general.php?page=mlang&tab=strings&s&group=' . __('Theme') . ': ' . wp_get_theme()->Name . '&paged=1'); ?>'; 136 <?php 137 } 138 else // for Polylang >= 2.1 139 { 140 ?> 141 window.<?php echo self::$prefix; ?>admin.attr.urls['polylang_strings'] = '<?php echo admin_url('admin.php?page=mlang_strings'); ?>'; 142 window.<?php echo self::$prefix; ?>admin.attr.urls['polylang_strings_theme_current'] = '<?php echo admin_url('admin.php?page=mlang_strings&s&group=' . __('Theme') . ': ' . wp_get_theme()->Name . '&paged=1'); ?>'; 143 <?php 144 } 145 146 ?> 122 147 123 148 window.<?php echo self::$prefix; ?>admin.lng[10] = '<?php _e('Polylang Theme Strings'); ?>'; … … 145 170 if (typeof(window.<?php echo self::$prefix; ?>admin) == 'object') 146 171 { 147 window.<?php echo self::$prefix; ?>admin.attr.urls['polylang_strings'] = '<?php echo admin_url('options-general.php?page=mlang&tab=strings'); ?>'; 172 window.<?php echo self::$prefix; ?>admin.attr.urls['polylang_strings'] = '<?php 173 174 if (defined('POLYLANG_VERSION') && (float)POLYLANG_VERSION < 2.1) 175 { 176 echo admin_url('options-general.php?page=mlang&tab=strings'); 177 } 178 else // for Polylang >= 2.1 179 { 180 echo admin_url('admin.php?page=mlang_strings'); 181 } 182 183 ?>'; 148 184 149 185 window.<?php echo self::$prefix; ?>admin.lng[70] = '<?php _e('Go to polylang-strings settings page'); ?>'; … … 199 235 is_admin() && 200 236 function_exists(self::$pll_f) && 201 (isset($_REQUEST['page']) && $_REQUEST['page'] == 'mlang') && 202 (isset($_REQUEST['tab']) && $_REQUEST['tab'] == 'strings') 237 isset($_REQUEST['page']) && 238 ( 239 ($_REQUEST['page'] == 'mlang' && isset($_REQUEST['tab']) && $_REQUEST['tab'] == 'strings') || 240 $_REQUEST['page'] == 'mlang_strings' // for Polylang >= 2.1 241 ) 203 242 ) 204 243 { -
polylang-theme-strings/trunk/readme.txt
r1580873 r1581815 5 5 Requires at least: 3.8 6 6 Tested up to: 4.7 7 Stable tag: 3.3. 17 Stable tag: 3.3.2 8 8 License: GPL2 9 9 … … 45 45 46 46 == Changelog == 47 48 = 3.3.2 (2017-01-25) = 49 50 * Added compatibility with Polylang 2.1 (Thanks to Mike Ambukadze for the report). 47 51 48 52 = 3.3.1 (2017-01-24) =
Note: See TracChangeset
for help on using the changeset viewer.