Hi there,
we use X theme version 7.2.3 and since a few days the logo alt tag is not shown correctly anymore. It is just empty.
We set the alt tag via Theme Options > Header > LOGO TEXT.
What is the cause for that?
Best regards
Hi there,
we use X theme version 7.2.3 and since a few days the logo alt tag is not shown correctly anymore. It is just empty.
We set the alt tag via Theme Options > Header > LOGO TEXT.
What is the cause for that?
Best regards
Howdy, @knowmates!
Thanks for writing in! That is certainly odd…can you confirm that you have text inside of this option in Theme Options? I know you mentioned it above, I’d just like to confirm:
The logo’s alt
text gets populated from there unless it is completely empty, in which case it falls back to the “name” of your site set in WordPress’ admin options.
If you have text in that input we might need to take a deeper look into this to see what’s going on. You can provide us with your WordPress login information in the Secure Note on your first post and we can take a look from there.
Hi @kory,
yes, I can confirm that we used the mentioned field to fill in the alt tag. Please have a look at the Secure Note.
I just noticed there is a PHP-update. Could that be the reason? To my mind it can’t.
Best regards
Hello @knowmates,
The logo alt text uses your site description. I have checked your site and indeed, there is no alt text in your logo. It is because in WP Admin > Settings > General, you have left the “Site Description” as blank.
By the way, with regards, to your PHP version, please check out our documentation on the requirements to run the theme for compatibility:
Best Regards.
Hello @ruenel,
to my mind the “Site Description” in WP Admin > Settings > General is not neccessary for getting an alt text for the logo. As mentioned above until now it was enough to fill in the logo text via theme options.
Nevertheless I copied the logo text from theme options to the “Site Description” and now the content is shown as alt tag and also title. How can I deactivate the title function?
We will check the PHP version.
Best regards
Hi @knowmates,
I’m not sure about your latest section if it’s still related to the logo text/description. May I know which title function you’re referring to? Is it a post title or title tag? If it’s a title tag then I recommend not removing it since it’s used for SEO and of course, the title of the entire page. If you wish to control it, you would need 3rd party SEO plugin. The title tag is based on Wordpress standard, the theme only displays what supplied to it.
Thanks!
Hi @rad,
of course I do not relate to the title tag of the homepage. I relate to the title tag of the logo.
I just wanted to set an alt tag. Usually I do that via Theme Options > Header > LOGO TEXT but in that case it did not work. So I additionally set the alt tag via WP Admin > Settings > General. Thus the alt tag of the logo is working but I also got a tooltip.
I was wondering how I can remove that tooltip again but to keep the alt tag of the logo.
Best regards
Hello @knowmates,
Normally, the tooltip in a link or image will only display if you have added a “title” attribute in the element. We do not have this attribute in the logo. You must have added it in your child theme. Please go Appearance > Theme Editor and find the _brand.php
. Most probably this file is located in wp-content/themes/x-child/framework/legacy/cranium/headers/views/global/
. Delete or remove any title attribute in the code. The default code of this file only contains this one:
<?php
// =============================================================================
// VIEWS/GLOBAL/_BRAND.PHP
// -----------------------------------------------------------------------------
// Outputs the brand.
// =============================================================================
$option_logo_text = x_get_option( 'x_logo_text' );
$option_logo_src = x_get_option( 'x_logo' );
$logo_text = ( empty( $option_logo_text ) ) ? get_bloginfo( 'name' ) : $option_logo_text;
if ( empty( $option_logo_src ) ) {
$logo_output = $logo_text;
} else {
$logo_src = x_make_protocol_relative( $option_logo_src );
$logo_output = '<img src="' . $logo_src . '" alt="' . $logo_text . '">';
}
if ( x_get_option( 'x_logo_visually_hidden_h1' ) ) {
echo '<h1 class="visually-hidden">' . $logo_text . '</h1>';
}
?>
<a href="<?php echo home_url( '/' ); ?>" class="<?php x_brand_class(); ?>">
<?php echo $logo_output; ?>
</a>
If this is NOT helping, provide us access to your site so that we can check your settings. Please create a secure note with the following info:
– Link to your site
– WordPress Admin username / password
To know how to create a secure note, please check this out: https://theme.co/docs/getting-support
Regards.
This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.