znuny / Znuny4OTRS-ExternalURLJump

With this extention you will be able to add external links to OTRS agent and customer navigation bar.
https://www.znuny.com/en/add-ons
6 stars 4 forks source link

How open the external URL link in a new blank window? #1

Closed micshi closed 11 years ago

micshi commented 11 years ago

I have a question.

How open the external URL link in a new blank window?

Thanks.

martini commented 11 years ago

Hi Micshi,

this is not possible at the moment.

An additional java script file is needed. Do you have skills to implement this? If yes, just push it via git.

Thanks,

-Martin

micshi commented 11 years ago

No, I have no any skill in java script.

Thanks,

micshi

martini commented 11 years ago

Hi Micshi,

there was also an easier way. It's implemented in version 1.0.4 now https://github.com/downloads/znuny/Znuny4OTRS-ExternalURLJump/Znuny4OTRS-ExternalURLJump-1.0.4.opm

Unfortunately it's only working in agent interface, in customer interface there is a missing attribute in Kernel/Output/HTML/Standard/CustomerNavigationBar.dtl, you need to add the following to the <a href=""> tag:

<a href="$Env{"Baselink"}$Data{"Link"}" accesskey="$QData{"AccessKey"}" title="$Text{"$Data{"Name"}"} ($QData{"AccessKey"})">

to

<a href="$Env{"Baselink"}$Data{"Link"}" accesskey="$QData{"AccessKey"}" title="$Text{"$Data{"Name"}"} ($QData{"AccessKey"})" $Data{"LinkOption"}>

Then it's also working in customer interface (the attribute is supported by OTRS config mechanism, but the attribute got lost in the .dtl file).

Enjoy,

-Martin

micshi commented 11 years ago

Hi Martin,

The new version 1.0.4 works perfect as you described and I noticed that you added a new configuration option "Target=_blank" to LinkOption in the xml file.

Thanks, micshi

martini commented 11 years ago

Thanks for feedback!

Yes, exactly. This was the magic https://github.com/znuny/Znuny4OTRS-ExternalURLJump/commit/78bcd5c6d106213a7350cdd17bd27eead33515bb

Enjoy!

-Martin

martini commented 11 years ago

PS: Are you from germany?

micshi commented 11 years ago

I am from China.

micshi

martini commented 11 years ago

Cool. Where from china?

PS: Where did you find this extension?

micshi commented 11 years ago

From Beijing, China.

I got to know Znunny via the following post http://forums.otterhub.org/viewtopic.php?f=53&t=16996.

I also know you are greate guy, the creator of OTRS.

micshi

martini commented 11 years ago

Thanks for feedback. I hope you will enjoy the Znuny-Addons.

-Martin