News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Header Banner Image Url Problem

Started by isytamer71, December 15, 2022, 08:52:32 AM

Previous topic - Next topic

isytamer71

My smf forums recently underwent a server change and now the header image banner is not linked to the main page. I have looked and looked to try and find the the css/index file under themes and layout settings to find this url link and change it to the right one. Could anyone point me in the right direction for where I can find this header banner image link url to change it? Thank You!

Doug Heffernan

Have a look at the option called: Logo image URL located under Theme Settings.

isytamer71

Quote from: Doug Heffernan on December 15, 2022, 09:04:43 AMHave a look at the option called: Logo image URL located under Theme Settings.


I must be on overload, where is this located in the admin section. I am assuming it is in the themes and layout section?

isytamer71

This is all I seem to see, probably not in the right area.

isytamer71

If this is what your talking about. I need to change the link this goes to when clicked not the actual image itself.

Doug Heffernan

Quote from: isytamer71 on December 15, 2022, 09:28:49 AMIf this is what your talking about. I need to change the link this goes to when clicked not the actual image itself.


Yes, that is the one.

isytamer71

#6
The image itself isn't the problem. It is not linked to the correct web address. I need to change that. Any ideas on where I can find this and change it? Thanks for the help.

Doug Heffernan

Quote from: isytamer71 on December 15, 2022, 09:41:06 AMThe image itself isn't the problem. It is not linked to the correct web address. I need to change that. Any ideas on where I can find this and change it? Thanks for the help.

At the index.template.php file of the theme that you are using as default, find this code:

<a href="', $scripturl, '">', empty($context['header_logo_url_html_safe']) ? $context['forum_name'] : '<img src="' . $context['header_logo_url_html_safe'] . '" alt="' . $context['forum_name'] . '" />', '</a>
And replace it with this:

<a href="redirection_url_link_here">', empty($context['header_logo_url_html_safe']) ? $context['forum_name'] : '<img src="' . $context['header_logo_url_html_safe'] . '" alt="' . $context['forum_name'] . '" />', '</a>
Replace redirection_url_link_here with the actual link that you want your logo to point to when clicked upon.

isytamer71

Any clue at to a quick way to navigate to this in the index template php file?

isytamer71

I found it. It begins on the third part with line 168. Thank You!

It is now fixed!

Doug Heffernan

Quote from: isytamer71 on December 15, 2022, 10:15:10 AMI found it. It begins on the third part with line 168. Thank You!

It is now fixed!

Glad to hear that. I am marking this as solved.

Advertisement: