Zen Cart Logo
Forums / Basic Configuration / How add target=_blank for tools_dhtml.php ?

How add target=_blank for tools_dhtml.php ?

Views: 2,092

Results 1 to 5 of 5
6 Apr 2007, 2:05 PM
#1
dogtags avatar

dogtags

Totally Zenned

Join Date:
Nov 2003
Posts:
876
Plugin Contributions:
1

How add target=_blank for tools_dhtml.php ?

I'd like some of the Tools to open in new windows (I have firefox to open new windows as new tabs)

How would I add target=_blank to the following link:

$za_contents[] = array('text' => BOX_TOOLS_DEVELOPERS_TOOL_KIT, 'link' => zen_href_link(FILENAME_DEVELOPERS_TOOL_KIT, '', 'NONSSL'));

Many thanks :smile:

6 Apr 2007, 5:50 PM
#2
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: How add target=_blank for tools_dhtml.php ?

Ctrl T and paste the URL works good too ... :cool:

6 Apr 2007, 8:02 PM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: How add target=_blank for tools_dhtml.php ?

I usually just right-click the link and choose New Tab.

But if you insist on changing code, try changing this:

zen_href_link(FILENAME_DEVELOPERS_TOOL_KIT, '', 'NONSSL'));

to this:

zen_href_link(FILENAME_DEVELOPERS_TOOL_KIT, '', 'NONSSL') . '" target="_blank');
7 Apr 2007, 12:33 AM
#4
dogtags avatar

dogtags

Totally Zenned

Join Date:
Nov 2003
Posts:
876
Plugin Contributions:
1

Re: How add target=_blank for tools_dhtml.php ?

Thanks, both. I've been doing right click/new tab, just wanted to save clicks. I tried your code, Dr, and it worked great. Thanks so much :smile:

31 Mar 2011, 7:45 PM
#5
ljdream00 avatar

ljdream00

Zen Follower

Join Date:
Jun 2007
Location:
Michigan
Posts:
168
Plugin Contributions:
0

Re: How add target=_blank for tools_dhtml.php ?

:clap:wow, this thread is 4 years old!!! but exactly what i needed!!! thanks

DrByte:

I usually just right-click the link and choose New Tab.

But if you insist on changing code, try changing this:

zen_href_link(FILENAME_DEVELOPERS_TOOL_KIT, '', 'NONSSL'));

> ```
zen_href_link(FILENAME_DEVELOPERS_TOOL_KIT, '', 'NONSSL') . '" target="_blank');