Page 1 of 1

How to open new Tab/window from hooks/links-navmenu?

Posted: 2019-07-09 10:05
by ronwill
Hi,

I've tried several methods but no luck!

How do I change this:
* You can add custom links to the navigation menu by appending them here ...
* The format for each link is:
$navLinks[] = array(
'url' => 'https://mywebsite.com/index.php',
'title' => 'Link title',
'groups' => array('group1', 'group2'), // groups allowed to see this link, use '*' if you want to show the link to all groups
'icon' => 'path/to/icon',
'table_group' => 0, // optional index of table group, default is 0
);
*/

To open my url link in a new window/tab instead of parent tab?

Cheers, Ron

Re: How to open new Tab/window from hooks/links-navmenu?

Posted: 2019-07-09 13:28
by pbottcher
Hi,

use

Code: Select all

'url' => 'https://mywebsite.com/index.php"  target="_blank',

Re: How to open new Tab/window from hooks/links-navmenu?

Posted: 2019-07-09 15:52
by ronwill
Excellent, that worked....

I was trying: 'url' => 'https://mywebsite.com/index.php target=_blank',
and few variations of that with no luck, yours works fine.


Thanks for your quick positive result,
Cheers, Ron