Changeset 3079625
- Timestamp:
- 04/30/2024 07:23:40 PM (22 months ago)
- Location:
- menu-in-post
- Files:
-
- 10 edited
- 1 copied
-
tags/1.3 (copied) (copied from menu-in-post/trunk)
-
tags/1.3/admin/help-tabs.php (modified) (2 diffs)
-
tags/1.3/js/main-min.js (modified) (1 diff)
-
tags/1.3/js/main.js (modified) (1 diff)
-
tags/1.3/menu-in-post.php (modified) (2 diffs)
-
tags/1.3/readme.txt (modified) (2 diffs)
-
trunk/admin/help-tabs.php (modified) (2 diffs)
-
trunk/js/main-min.js (modified) (1 diff)
-
trunk/js/main.js (modified) (1 diff)
-
trunk/menu-in-post.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
menu-in-post/tags/1.3/admin/help-tabs.php
r2993551 r3079625 40 40 switch($name) { 41 41 case 'shortcode_builder': 42 $content['shortcode_builder'] = '<p>' . 42 $content['shortcode_builder'] = '<h2>' . 43 __( 44 'Shortcode Builder Options', 45 'menu-in-post' 46 ) . '</h2>'; 47 $content['shortcode_builder'] .= '<p>' . 43 48 __( 44 49 'Use the Shortcode Builder to create a menu shortcode. ' . … … 129 134 'variables to a menu item, you should use the Custom Link ' . 130 135 'option for the menu item.', 136 'menu-in-post' 137 ) . '</p>'; 138 $content['shortcode_builder'] .= '<h2>' . 139 __( 140 'Open Links In a New Tab or Window', 141 'menu-in-post' 142 ) . '</h2>'; 143 $content['shortcode_builder'] .= '<p>' . 144 __( 145 'Menu In Post honors WordPress menu item settings, ' . 146 'so you can set the desired target of each menu item ' . 147 'in both list- and dropdown-style menus.', 148 'menu-in-post' 149 ) . '</p>'; 150 $content['shortcode_builder'] .= '<p>' . 151 __( 152 'In order to force Menu in Post to open links in both ' . 153 'list- and dropdown-style menus in a new tab or window, ' . 154 'open the menu in Admin > Appearance > Menus.', 155 'menu-in-post' 156 ) . '</p>'; 157 $content['shortcode_builder'] .= '<p>' . 158 __( 159 'Note: Some block-enabled themes disable the Menus entry in ' . 160 'the Appearance menu, so if you do not see it, try ' . 161 'going to Settings > Menu In Post in WordPress Admin, ' . 162 'and setting "Show Appearance > Menus" to ' . 163 '"yes".', 164 'menu-in-post' 165 ) . '</p>'; 166 $content['shortcode_builder'] .= '<p>' . 167 __( 168 'On the Appearance > Menus page with your menu selected, ' . 169 'enable the the Advanced Menu Properties option ' . 170 '"Link Target" if it is not already enabled ' . 171 'by clicking the Screen Options tab and selecting it.', 172 'menu-in-post' 173 ) . '</p>'; 174 175 $content['shortcode_builder'] .= '<p>' . 176 __( 177 'Check the option "Open link in a new tab" for ' . 178 'each menu item you want to open in a new tab or window.', 179 'menu-in-post' 180 ) . '</p>'; 181 $content['shortcode_builder'] .= '<p>' . 182 __( 183 'The settings in the user's browser will determine ' . 184 'whether the link opens in a new tab or window.', 131 185 'menu-in-post' 132 186 ) . '</p>'; -
menu-in-post/tags/1.3/js/main-min.js
r2228060 r3079625 1 jQuery(document).ready(function(){jQuery( ".mip-drop-nav").change(function(){document.location.href=jQuery(this).val()})});1 jQuery(document).ready(function(){jQuery('.mip-drop-nav').change(function(){let url=jQuery(this).val(),destination=jQuery(this).find(':selected').data('target');if(typeof destination!=='undefined'){window.open(url,destination);}else{document.location.href=url;}});}); -
menu-in-post/tags/1.3/js/main.js
r2434726 r3079625 3 3 jQuery('.mip-drop-nav').change( 4 4 function () { 5 document.location.href = jQuery(this).val(); 5 let url = jQuery(this).val(), 6 destination = jQuery(this).find(':selected').data('target'); 7 if (typeof destination !== 'undefined') { 8 window.open(url, destination); 9 } else { 10 document.location.href = url; 11 } 6 12 } 7 13 ); -
menu-in-post/tags/1.3/menu-in-post.php
r2994821 r3079625 6 6 * Author URI: https://profiles.wordpress.org/linux4me2 7 7 * Text Domain: menu-in-post 8 * Version: 1. 2.68 * Version: 1.3 9 9 * License: GPL3 10 10 * License URI: https://www.gnu.org/licenses/gpl-3.0-standalone.html … … 227 227 } 228 228 229 // Get the target, if any. 230 if (!empty($item->target)) { 231 $attributes .= ' data-target="' . esc_attr($item->target) . '"'; 232 } 233 229 234 // Add selected attribute if menu item is the current page. 230 235 if ($item->current) { -
menu-in-post/tags/1.3/readme.txt
r3064076 r3079625 5 5 Tested up to: 6.5 6 6 Requires PHP: 7.4 7 Stable tag: 1. 2.67 Stable tag: 1.3 8 8 License: GPLv3 9 9 License URI: https://www.gnu.org/licenses/gpl-3.0-standalone.html … … 62 62 63 63 == Changelog == 64 65 = 1.3 = 66 67 * Add honoring WordPress menu item target with dropdown-style menus. 64 68 65 69 = 1.2.6 = -
menu-in-post/trunk/admin/help-tabs.php
r2993551 r3079625 40 40 switch($name) { 41 41 case 'shortcode_builder': 42 $content['shortcode_builder'] = '<p>' . 42 $content['shortcode_builder'] = '<h2>' . 43 __( 44 'Shortcode Builder Options', 45 'menu-in-post' 46 ) . '</h2>'; 47 $content['shortcode_builder'] .= '<p>' . 43 48 __( 44 49 'Use the Shortcode Builder to create a menu shortcode. ' . … … 129 134 'variables to a menu item, you should use the Custom Link ' . 130 135 'option for the menu item.', 136 'menu-in-post' 137 ) . '</p>'; 138 $content['shortcode_builder'] .= '<h2>' . 139 __( 140 'Open Links In a New Tab or Window', 141 'menu-in-post' 142 ) . '</h2>'; 143 $content['shortcode_builder'] .= '<p>' . 144 __( 145 'Menu In Post honors WordPress menu item settings, ' . 146 'so you can set the desired target of each menu item ' . 147 'in both list- and dropdown-style menus.', 148 'menu-in-post' 149 ) . '</p>'; 150 $content['shortcode_builder'] .= '<p>' . 151 __( 152 'In order to force Menu in Post to open links in both ' . 153 'list- and dropdown-style menus in a new tab or window, ' . 154 'open the menu in Admin > Appearance > Menus.', 155 'menu-in-post' 156 ) . '</p>'; 157 $content['shortcode_builder'] .= '<p>' . 158 __( 159 'Note: Some block-enabled themes disable the Menus entry in ' . 160 'the Appearance menu, so if you do not see it, try ' . 161 'going to Settings > Menu In Post in WordPress Admin, ' . 162 'and setting "Show Appearance > Menus" to ' . 163 '"yes".', 164 'menu-in-post' 165 ) . '</p>'; 166 $content['shortcode_builder'] .= '<p>' . 167 __( 168 'On the Appearance > Menus page with your menu selected, ' . 169 'enable the the Advanced Menu Properties option ' . 170 '"Link Target" if it is not already enabled ' . 171 'by clicking the Screen Options tab and selecting it.', 172 'menu-in-post' 173 ) . '</p>'; 174 175 $content['shortcode_builder'] .= '<p>' . 176 __( 177 'Check the option "Open link in a new tab" for ' . 178 'each menu item you want to open in a new tab or window.', 179 'menu-in-post' 180 ) . '</p>'; 181 $content['shortcode_builder'] .= '<p>' . 182 __( 183 'The settings in the user's browser will determine ' . 184 'whether the link opens in a new tab or window.', 131 185 'menu-in-post' 132 186 ) . '</p>'; -
menu-in-post/trunk/js/main-min.js
r2228060 r3079625 1 jQuery(document).ready(function(){jQuery( ".mip-drop-nav").change(function(){document.location.href=jQuery(this).val()})});1 jQuery(document).ready(function(){jQuery('.mip-drop-nav').change(function(){let url=jQuery(this).val(),destination=jQuery(this).find(':selected').data('target');if(typeof destination!=='undefined'){window.open(url,destination);}else{document.location.href=url;}});}); -
menu-in-post/trunk/js/main.js
r2434726 r3079625 3 3 jQuery('.mip-drop-nav').change( 4 4 function () { 5 document.location.href = jQuery(this).val(); 5 let url = jQuery(this).val(), 6 destination = jQuery(this).find(':selected').data('target'); 7 if (typeof destination !== 'undefined') { 8 window.open(url, destination); 9 } else { 10 document.location.href = url; 11 } 6 12 } 7 13 ); -
menu-in-post/trunk/menu-in-post.php
r2994821 r3079625 6 6 * Author URI: https://profiles.wordpress.org/linux4me2 7 7 * Text Domain: menu-in-post 8 * Version: 1. 2.68 * Version: 1.3 9 9 * License: GPL3 10 10 * License URI: https://www.gnu.org/licenses/gpl-3.0-standalone.html … … 227 227 } 228 228 229 // Get the target, if any. 230 if (!empty($item->target)) { 231 $attributes .= ' data-target="' . esc_attr($item->target) . '"'; 232 } 233 229 234 // Add selected attribute if menu item is the current page. 230 235 if ($item->current) { -
menu-in-post/trunk/readme.txt
r3064076 r3079625 5 5 Tested up to: 6.5 6 6 Requires PHP: 7.4 7 Stable tag: 1. 2.67 Stable tag: 1.3 8 8 License: GPLv3 9 9 License URI: https://www.gnu.org/licenses/gpl-3.0-standalone.html … … 62 62 63 63 == Changelog == 64 65 = 1.3 = 66 67 * Add honoring WordPress menu item target with dropdown-style menus. 64 68 65 69 = 1.2.6 =
Note: See TracChangeset
for help on using the changeset viewer.