Advertisement

Favicon Joomla 4.1.2 Topic is solved

This forum is for general questions about extensions for Joomla! 4.x.

Moderators: pe7er, General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Locked
sfurgo
Joomla! Apprentice
Joomla! Apprentice
Posts: 42
Joined: Tue Dec 12, 2017 7:56 pm

Favicon Joomla 4.1.2

Post by sfurgo » Tue Apr 12, 2022 6:57 pm

Hello all,

I am trying to find an extension or a way to add a Favicon to my Joomla 4.1.2 website.

Apparently there is no extension currently to modify this important feature.

Any ideas or suggestions?

Thank you for your support.

Regards.

Advertisement
User avatar
drmenzelit
Joomla! Intern
Joomla! Intern
Posts: 85
Joined: Sat Oct 22, 2011 8:30 am
Contact:

Re: Favicon Joomla 4.1.2

Post by drmenzelit » Wed Apr 13, 2022 10:36 am

You don't need an extension for that.
Cassiopeia loads 3 favicons:

Code: Select all

$this->addHeadLink(HTMLHelper::_('image', 'joomla-favicon.svg', '', [], true, 1), 'icon', 'rel', ['type' => 'image/svg+xml']);
$this->addHeadLink(HTMLHelper::_('image', 'favicon.ico', '', [], true, 1), 'alternate icon', 'rel', ['type' => 'image/vnd.microsoft.icon']);
$this->addHeadLink(HTMLHelper::_('image', 'joomla-favicon-pinned.svg', '', [], true, 1), 'mask-icon', 'rel', ['color' => '#000']);
If you store 3 files with these names (joomla-favicon.svg, favicon.ico and joomla-favicon-pinned.svg) in media/templates/site/cassiopeia/images, these files will be used instead of the standard ones.
Another possibility is to create a child template, make a copy of the index.php and change the code for the favicons.

User avatar
ceford
Joomla! Virtuoso
Joomla! Virtuoso
Posts: 3281
Joined: Mon Feb 24, 2014 10:38 pm
Location: Edinburgh, Scotland
Contact:

Re: Favicon Joomla 4.1.2

Post by ceford » Wed Apr 13, 2022 3:21 pm

See this for where to put your custom favicons:

https://docs.joomla.org/J4.x:Cassiopeia ... s#Favicons

[Is that still good for J4.1.2?]

User avatar
drmenzelit
Joomla! Intern
Joomla! Intern
Posts: 85
Joined: Sat Oct 22, 2011 8:30 am
Contact:

Re: Favicon Joomla 4.1.2

Post by drmenzelit » Wed Apr 13, 2022 4:13 pm

ceford wrote: Wed Apr 13, 2022 3:21 pm See this for where to put your custom favicons:

https://docs.joomla.org/J4.x:Cassiopeia ... s#Favicons

[Is that still good for J4.1.2?]
Yes, the doc has to be updated a little bit because the images folder for Cassiopeia is now under media/templates/site/cassiopeia

Advertisement

Locked

Return to “Extensions for Joomla! 4.x”