December 8, 2013 at 3:04 am #1762
Hi! I just purchased the theme 🙂
How do you direct a menu bar item to open in a NEW TAB? Some of the menu options on my main navigation bar need to lead offsite but I don’t want them to open in the existing browser window, rather I would like them to open in a _blank tab.
December 8, 2013 at 3:25 am #1765
- This topic was modified 4 years, 3 months ago by shortninja.
Also, I would like to apply this “open in new browser” feature to the social media icons on the main menu bar (and anywhere else they may appear) as well. Thanks again!December 8, 2013 at 8:20 am #1770
Hi, thank you for purchasing our theme.
please add this code at the bottom before ‘})’ in file js/custom.theme.js,
jQuery('a.social_active').attr('target', '_blank'); jQuery('li.menu-item a').attr('target', '_blank');
December 9, 2013 at 1:01 am #1776
- This reply was modified 4 years, 3 months ago by Johnny.
Thank you for the response! The hack code you sent works, however this code applies the “_blank” to ALL the menu buttons which won’t work well for this website. My client needs only a select few of the menu buttons to open in a new tab, and the rest need to function normally opening in the same browser. In other WP themes I’ve used there is a checkbox option on the menu item that you can select to have just that particular individual menu button open in a new browser, without effecting the rest of the menu. I’m guessing this is a pretty standard feature. Here is a screenshot of what it should look like: http://www.shannonames.com/dev2/wp-content/uploads/2013/12/menu_option_screenshot.jpg
Is it possible the menu creation interface is an older version? If so how would I update this to the current version that provides this function?
Thanks again for your help with this!December 9, 2013 at 1:27 am #1778
When viewing the menu administration page, click on Screen Options (top right), and check the box labelled Link Target under the Show advanced menu properties heading. then option ‘Open link in a new window/tab’ will show,
BestDecember 9, 2013 at 2:22 am #1779
Yes! There is that pesky hidden feature. Thank you!! And thanks for the social media code earlier as well! Works perfectly ;o) xxDecember 13, 2013 at 9:30 am #1863
Hi again…is there also an option to make the individual “buttons” from the button module to lead to a ‘_blank’ new tab? If not, do you have a custom code I can add and if so where do I add it? Thank you!December 14, 2013 at 5:04 am #1868
Hi, please add below code at the bottom before ‘})’ in file js/custom.theme.js for button module click open new tab:
BestDecember 19, 2013 at 8:20 am #1908
Thank you!!February 20, 2014 at 5:14 am #2452
Hi, the buttons in the promote module doesn’t open in new tab, how could I do this?February 20, 2014 at 12:12 pm #2461
Hi, please open file bee/functions/functions-view-module.php and find line 1577(or about), replace this
BestFebruary 20, 2014 at 2:26 pm #2462
Thanks, it works
You must be logged in to reply to this topic.