Correct way to change the Favorite/Shortcut Icon
Moderator: crythias
Correct way to change the Favorite/Shortcut Icon
Hi guys and girls,
i tried to change the fav-icon for my OTRS 5.0.16 installation, following the OTRS manual (creating my own theme, ...).
http://doc.otrs.com/doc/manual/admin/st ... hemes.html
I created my own skin (which is working fine) and theme (which is NOT working).
The one and only task for the theme is, to change fav icon.
What did i do?
I created /opt/otrs/Kernel/Output/HTML/Templates/custom/ folder for my theme.
Then i copied the files HTMLHead.tt and Login.tt from the Standard folder to my custom folder.
I edited the files and changed the product.ico path to match the new icon (<link rel="shortcut icon" href="/otrs-web/skins/Agent/custom/img/icons/product.ico" type="image/ico" />).
Afterwards i added the theme in the SysConfig Frontend::Themes and selected the theme for my user.
OTRS says "updated successfully", but the fav-icon stays the same.
Which step did i miss this time?
Best regards
Alcesh
i tried to change the fav-icon for my OTRS 5.0.16 installation, following the OTRS manual (creating my own theme, ...).
http://doc.otrs.com/doc/manual/admin/st ... hemes.html
I created my own skin (which is working fine) and theme (which is NOT working).
The one and only task for the theme is, to change fav icon.
What did i do?
I created /opt/otrs/Kernel/Output/HTML/Templates/custom/ folder for my theme.
Then i copied the files HTMLHead.tt and Login.tt from the Standard folder to my custom folder.
I edited the files and changed the product.ico path to match the new icon (<link rel="shortcut icon" href="/otrs-web/skins/Agent/custom/img/icons/product.ico" type="image/ico" />).
Afterwards i added the theme in the SysConfig Frontend::Themes and selected the theme for my user.
OTRS says "updated successfully", but the fav-icon stays the same.
Which step did i miss this time?
Best regards
Alcesh
OS: CentOS 7.1
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
-
- Znuny guru
- Posts: 2210
- Joined: 13 Mar 2014, 09:16
- Znuny Version: 6.0.14
- Real Name: Rolf Straub
Re: Correct way to change the Favorite/Shortcut Icon
Try using:
~otrs/Custom/[...] instead.
Just make sure to keep the same folder-structure.
~otrs/Custom/[...] instead.
Just make sure to keep the same folder-structure.
Currently using: OTRS 6.0.14 -- MariaDB -- Ubuntu 16 LTS
Re: Correct way to change the Favorite/Shortcut Icon
You mean like this?RStraub wrote:Try using:
~otrs/Custom/[...] instead.
Just make sure to keep the same folder-structure.
/otrs-web/custom/img/icons/product.ico
PS: To me, it seems like the theme isn't used correctly.
I used FireBug to check the used path to the product.ico --> href="/otrs-web/skins/Agent/default/img/icons/product.ico"
If i manualy change it to the custom directory (with FireBug), it works fine --> href="/otrs-web/skins/Agent/custom/img/icons/product.ico"
Do i have to add more than just the Frontend::Themes entry to get the theme to work?
I created a new entry with custom (same name as the directory) as the name.
OS: CentOS 7.1
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
-
- Znuny expert
- Posts: 167
- Joined: 26 Nov 2014, 20:34
- Znuny Version: 6.3.4
- Real Name: Samuel Casimiro
- Company: Câmara dos Deputados
- Contact:
Re: Correct way to change the Favorite/Shortcut Icon
No, I think.
You img path looks just fine. It's your HTMLHead.tt path that is wrong. Try /opt/otrs/Custom/Kernel/Output/HTML/Templates/... instead.
You img path looks just fine. It's your HTMLHead.tt path that is wrong. Try /opt/otrs/Custom/Kernel/Output/HTML/Templates/... instead.
Samuel
Znuny 6.3.4 | OTRS 5.0.17
OS: Debian 11 | CentOS 6.5
Database: Postgres | Oracle 12.1
Number of agents: 450 | Number of customers: 20000 | Number of CIs: 30000
Znuny 6.3.4 | OTRS 5.0.17
OS: Debian 11 | CentOS 6.5
Database: Postgres | Oracle 12.1
Number of agents: 450 | Number of customers: 20000 | Number of CIs: 30000
Re: Correct way to change the Favorite/Shortcut Icon
hmmmm i tired your solution.nedmaj wrote:No, I think.
You img path looks just fine. It's your HTMLHead.tt path that is wrong. Try /opt/otrs/Custom/Kernel/Output/HTML/Templates/... instead.
1. The path ended with /opt/otrs/Custom/Kernel/Output. ../HTML/Templates was missing --> created.
2. I copied my custom skin there.
3. I restarted the apache and my browser
--> Still the normal fav-icon.
Also the guide from OTRS themself points to the path that i originaly used.
Soooo lets try it with a little more information about the steps i took and why:OTRS Guide wrote: Create a directory called Kernel/Output/HTML/Templates/Company and copy all files that you like to change, from Kernel/Output/HTML/Templates/Standard into the new folder.
1. I am creating a new skin for my company. The skin itself with the new design is finished - only the fav-icon is left to change.
2. I can't change the fav-icon within the skin (css files) - right? Thats what i need the theme for.
3. I took the corresponding administration manual for our OTRS.
4. I created the custom directory and copied the files that contain the reference to the fav-icon.
5. I manualy changed the fav-icon path in my browser with FireBug to check if the path i want to use is actualy accessable/working. --> It works.
6. I changed the path to the fav-icon within the Header.tt, Login.tt, AgentTicketSearchOpenSearchDescriptionTicketNumber.tt and AgentTicketSearchOpenSearchDescriptionFulltext.tt from the variable path to the hard coded path.
7. I entered the name of the new theme (same name as the folder) within SysConfig Frontend::Themes and set it to 1.
8. I restarted the httpd and my browser.
9. I selected the new theme for my user --> good old default fav-icon
OS: CentOS 7.1
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
-
- Znuny expert
- Posts: 167
- Joined: 26 Nov 2014, 20:34
- Znuny Version: 6.3.4
- Real Name: Samuel Casimiro
- Company: Câmara dos Deputados
- Contact:
Re: Correct way to change the Favorite/Shortcut Icon
If you edit a copy of your files inside /opt/otrs/Custom/.../Templates/Standard you don't need to create a theme.
Have you checked if the theme name (path Templates/ThemeName) is the same name you set up at Framework > Core (DefautTheme)?
Have you checked if the theme name (path Templates/ThemeName) is the same name you set up at Framework > Core (DefautTheme)?
Samuel
Znuny 6.3.4 | OTRS 5.0.17
OS: Debian 11 | CentOS 6.5
Database: Postgres | Oracle 12.1
Number of agents: 450 | Number of customers: 20000 | Number of CIs: 30000
Znuny 6.3.4 | OTRS 5.0.17
OS: Debian 11 | CentOS 6.5
Database: Postgres | Oracle 12.1
Number of agents: 450 | Number of customers: 20000 | Number of CIs: 30000
-
- Administrator
- Posts: 3960
- Joined: 18 Dec 2007, 12:23
- Znuny Version: Znuny and Znuny LTS
- Real Name: Roy Kaldung
- Company: Znuny
- Contact:
Re: Correct way to change the Favorite/Shortcut Icon
When you search the template file you will find in
or
Due to the fact that the setting Frontend::ImagePath points to the default theme and other images can be found there I suggest to put all other images into your custom skin and put an overriding xml into your skin opm which adjusts the ImagePath from
<OTRS_CONFIG_Frontend::WebPath>skins/Agent/default/img/ to <OTRS_CONFIG_Frontend::WebPath>skins/Agent/custom/img/
- Kernel/Output/HTML/Templates/Standard/AgentTicketSearchOpenSearchDescriptionFulltext.tt
- Kernel/Output/HTML/Templates/Standard/AgentTicketSearchOpenSearchDescriptionTicketNumber.tt
- Kernel/Output/HTML/Templates/Standard/CustomerHTMLHead.tt
- Kernel/Output/HTML/Templates/Standard/CustomerTicketSearchOpenSearchDescription.tt
- Kernel/Output/HTML/Templates/Standard/HTMLHead.tt
- Kernel/Output/HTML/Templates/Standard/Login.tt
Code: Select all
<link rel="shortcut icon" href="[% Config("Frontend::ImagePath") %]icons/product.ico" type="image/ico" />
Code: Select all
<Image height="16" width="16" type="image/x-icon">[% Config("HttpType") %]://[% Config("FQDN") %][% Config("Frontend::ImagePath") %]icons/product.ico</Image>
<OTRS_CONFIG_Frontend::WebPath>skins/Agent/default/img/ to <OTRS_CONFIG_Frontend::WebPath>skins/Agent/custom/img/
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Re: Correct way to change the Favorite/Shortcut Icon
Hi root,root wrote: Due to the fact that the setting Frontend::ImagePath points to the default theme and other images can be found there I suggest to put all other images into your custom skin and put an overriding xml into your skin opm which adjusts the ImagePath from
<OTRS_CONFIG_Frontend::WebPath>skins/Agent/default/img/ to <OTRS_CONFIG_Frontend::WebPath>skins/Agent/custom/img/
this sounds like the clostest solution to what i was looking for - i hoped that i could only redirect the favicon (with manualy overwriting the path within the custom themes tt files) and the other files could stay in the default img directory (regarding future updates, compatibility etc.), but i think this is no possible solution at the moment.
If i understand it correctly, you are mentioning an overwriting XMl for my skin - would this effect other skins too or is this only affecting my custom skin?
Copying the original imgaes to the custom skin is no big deal.
Also, you are mentioning a skin opm - i never worked with opm's before and i couldn't find a good source of information about how to create one.
At the moment my skin is pretty simple, only consisting of some css files to overwrite colors, an XML file for our own logo and skin registration within the SysConfig.
Could you give me some advice for the path overwriting that you mentioned?
Thanks!
OS: CentOS 7.1
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
-
- Administrator
- Posts: 3960
- Joined: 18 Dec 2007, 12:23
- Znuny Version: Znuny and Znuny LTS
- Real Name: Roy Kaldung
- Company: Znuny
- Contact:
Re: Correct way to change the Favorite/Shortcut Icon
Your xml for the skin can be extended with
where you adjust the directory name.
Details on how to create opms can be found here: http://doc.otrs.com/doc/manual/develope ... lding.html
Code: Select all
<ConfigItem Name="Frontend::ImagePath" Required="1" Valid="1" ConfigLevel="200">
<Description Translatable="1">Defines the URL image path of icons for navigation.</Description>
<Group>Framework</Group>
<SubGroup>Core::Web</SubGroup>
<Setting>
<String Regex=""><OTRS_CONFIG_Frontend::WebPath>skins/Agent/default/img/</String>
</Setting>
</ConfigItem>
Details on how to create opms can be found here: http://doc.otrs.com/doc/manual/develope ... lding.html
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Re: Correct way to change the Favorite/Shortcut Icon
I set it up and the result is close (and somehow funny) - yet it doesn't workroot wrote:Your xml for the skin can be extended withwhere you adjust the directory name.Code: Select all
<ConfigItem Name="Frontend::ImagePath" Required="1" Valid="1" ConfigLevel="200"> <Description Translatable="1">Defines the URL image path of icons for navigation.</Description> <Group>Framework</Group> <SubGroup>Core::Web</SubGroup> <Setting> <String Regex=""><OTRS_CONFIG_Frontend::WebPath>skins/Agent/default/img/</String> </Setting> </ConfigItem>
I changed the Regex to fit my path (<String Regex=""><OTRS_CONFIG_Frontend::WebPath>skins/Agent/custom/img/</String>) and i copied everything from the default img folder to my custom/img folder.
The SysConfig now says, that my "custom" string should be the default, yet it still takes the ../default/.. path (Screenshots as attachment).
Do i have to set it manualy once?
If there is no other solution, then i have to force the custom path without the xml.... it just feels unprofessional after creating everything else as a separate skin
Note: I did the Rebuild Config, Clear Cache, restart server etc.
You do not have the required permissions to view the files attached to this post.
OS: CentOS 7.1
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
-
- Administrator
- Posts: 3960
- Joined: 18 Dec 2007, 12:23
- Znuny Version: Znuny and Znuny LTS
- Real Name: Roy Kaldung
- Company: Znuny
- Contact:
Re: Correct way to change the Favorite/Shortcut Icon
The XML-file were opened in alphabetical order try renaming your file CustomSkin.xml that it's read after Framework.xml
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Re: Correct way to change the Favorite/Shortcut Icon
Tried and failed.... i don't know if our OTRS hates meroot wrote:The XML-file were opened in alphabetical order try renaming your file CustomSkin.xml that it's read after Framework.xml
Any more tips or tricks where i'm failing? Otherwise i will change the path directly in the SysConfig - i already copied all the images, so the basic reason for my question is solved anyway.
You do not have the required permissions to view the files attached to this post.
OS: CentOS 7.1
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
-
- Znuny guru
- Posts: 5018
- Joined: 13 Mar 2011, 09:54
- Znuny Version: 6.0.x
- Real Name: Renée Bäcker
- Company: Perl-Services.de
- Contact:
Re: Correct way to change the Favorite/Shortcut Icon
Go to SysConfig and reset the config option for the Frontend::ImagePath. As ZCustom....xml is read *after* the Framework.xml it should be set to the value defined in your ZCustom....xml. And that value should be written to the ZZZAuto.pm as well (or the entry in ZZZAuto.pm is deleted).
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Re: Correct way to change the Favorite/Shortcut Icon
I'm not 100% sure how the SysConfig relates to these config-files, e.g. when is ZZZAAuto and ZZZAuto updated, when the SysConfig is updated and so on, but your were completly right: After reseting the Path in the SysConfig, the ZZZAuto entry was deleted. Now it works.reneeb wrote:Go to SysConfig and reset the config option for the Frontend::ImagePath. As ZCustom....xml is read *after* the Framework.xml it should be set to the value defined in your ZCustom....xml. And that value should be written to the ZZZAuto.pm as well (or the entry in ZZZAuto.pm is deleted).
Thank you all for your help!
OS: CentOS 7.1
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes
OTRS: 5.0.16
DB: MySQL
Webserver: Apache with mod_perl
Packages: Znuny4OTRS-Repo
How often have I said to you that when you have eliminated the impossible, whatever remains, however improbable, must be the truth? - Sherlock Holmes