How to Add a Title tag to the Logo's A Href

Hi,

I’ve searched the support forum Hi and Low…can’t locate the answer to this on. I am trying to add a “title” tag to my logo. I’m using X pro. I am also interested in knowing HOW to edit the header to add the following code to my logo area:

<div itemscope itemtype="https://schema.org/Organization">
  <a class="brand brand-primary" itemprop="url" href="https://www.housebuyersanantonio.com/">
              <img itemprop="logo" class="brand-logo" src="https://cdn.oncarrot.com/uploads/sites/2176/2012/01/We-Sell-House-Fast-TX.jpg" alt="We Buy Houses San Antonio TX logo">
    
    <b itemprop="name">We Buy Houses San Antonio TX</b>
    <span class="tagline">Sell Your House Fast</span>
  </a>
</div>

Thank you for any help in advance…

Hi There @jvasquez3

Thanks for writing in! Please note that the customization requests are outside our scope of the support, but I can still point you to the right direction for you to perform the changes.

To change your template files, first you need to setup a child theme and activate it. To do that, please follow our child theme setup guide here (https://theme.co/apex/forum/t/setup-how-to-setup-child-themes/57).

Then you need to copy the file _brand.php which is located under /wp-content/themes/x/framework/legacy/cranium/headers/views/global/_brand.php into your child theme’s respective location /wp-content/themes/x-child/framework/legacy/cranium/headers/views/global/_brand.php.
``

Then you can edit the file using a text editor and add your customizations accordingly.

You can locate the following code where it outputs your logo and link.

<a href="<?php echo home_url( '/' ); ?>" class="<?php x_brand_class(); ?>">
  <?php echo $logo_output; ?>
</a>

Hope that helps.

Unfortunately, your solution didn’t work, I’m sure your instructions are correct, BUT, my changes to the _brand.php file are not being updated on the live site when I clear cache and refresh page.

I’ve created this directory: /wp-content/themes/pro-child/framework/legacy/cranium/headers/views/global/
and placed the _brand.php file inside of it as instructed but any change I make in that file is not reflected on page refresh…can you please help me a little more on this one? I’ve tried everything.

I’ve confirmed that I am using the X pro child theme currently.

Hi There,

I could see that all your pages are using the Pro header so copy the _brand.php file to child theme will not work, this file is used for the default header only.

I suggest you to replace logo image with the text element then copy the HTML code to the text element instead:

<div itemscope itemtype="https://schema.org/Organization">
	<a class="brand brand-primary" itemprop="url" href="https://www.housebuyersanantonio.com/">
		<img itemprop="logo" class="brand-logo" src="https://cdn.oncarrot.com/uploads/sites/2176/2012/01/We-Sell-House-Fast-TX.jpg" alt="We Buy Houses San Antonio TX logo">

		<b itemprop="name">We Buy Houses San Antonio TX</b>
		<span class="tagline">Sell Your House Fast</span>
	</a>
</div>

Hope it helps :slight_smile:

That worked perfectly, thank you!

You are most welcome. :slight_smile:

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.