Main menu Customization

Post about your customizations to share with others.

Moderators: Developer, Contributor

Post Reply
Mejstro
Posts: 24
Joined: 07 May 2014, 12:07

Main menu Customization

Post by Mejstro »

Hello,
I have added a custom menu item by modifying config_inc.php:

Code: Select all

$g_main_menu_custom_options = array(array("MyMenuItem", ADMINISTRATOR, 'MyLink' ) );
Now I would need to force open only this link in a new window. Would it be possible? Can anyone help me?
Thanks a lot for your answer and help...
atrol
Site Admin
Posts: 8366
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Main menu Customization

Post by atrol »

I prefer to choose on my own if I want to open a link in the same tab, a new tab or a new window.

But ok, if you want it, you can get it: http://www.w3schools.com/tags/att_a_target.asp
Please use Search before posting and read the Manual
Mejstro
Posts: 24
Joined: 07 May 2014, 12:07

Re: Main menu Customization

Post by Mejstro »

Thanks a lot for your answer. I know html syntax quite a well, but I suppose some files of mantis have to be modified to add target="_blank" parameter. Unfortunatelly I am unable to find where the change must be done.
Guevtron
Posts: 1
Joined: 20 Mar 2018, 20:31

Re: Main menu Customization

Post by Guevtron »

sorry for my bad English, but I wanted to answer this question that cost me a lot to resolve and although I know it's old the publication has not been closed.

In order to help more collaborators in the future, I commented on the solution.

add the following to the code

Code: Select all

$g_main_menu_custom_options = array(array("MyMenuItem", ADMINISTRATOR, 'MyLink" target="_blank' ) );
Post Reply