H1 tags

Hi,

may I know how do I check the H1 headings of my website? www.ulinkchina.com

Linda

Hello Linda,

Try this tool. I hope you can find it helpful.

Regards,
Kharis

Is there any way I can change the h2 tags to h1 tags?

For example, the header title on my main page now http://ulinkchina.com/ is h2 class.

Is it by default that way? Or can I change it to h1?

This is for SEO purposes.

Thanks,
Linda

Same question here. The front page of my website (www.bokashiliving.com) has no h1 or h2 headings. Is this a problem for SEO (online tools suggest it is)? If so, how can I fix it?

Thanks in advance
Nicki

Hello Nicki,

Try to attach H1 tag on your site logo by doing the following steps:

  1. Install and activate this plugin
  2. Go to custom functions editor, and then paste this code into it.

Regards,
Kharis

Hello Linda,

I would like to apologize in advance for the delay. Please try to follow the instruction suggested to Nicki above. But for the code, use this one:


function rocked_branding() {
	if ( get_theme_mod('site_logo') ) :
		echo '<a href="' . esc_url( home_url( '/' ) ) . '" title="' . esc_attr(get_bloginfo('name')) . '"><h1 style="margin:0; line-height:1px;"><img class="site-logo" src="' . esc_url(get_theme_mod('site_logo')) . '" alt="' . esc_attr(get_bloginfo('name')) . '" /></h1></a>';
	else :
		echo '<h1 class="site-title"><a href="' . esc_url(home_url( '/' )) . '" rel="home">' . esc_html(get_bloginfo('name')) . '</a></h1>';
		if ( get_bloginfo( 'description' ) ) {
		echo '<h2 class="site-description">' . esc_html(get_bloginfo( 'description' )) . '</h2>';
		}
	endif;
}

Let me know how it goes.

Regards,
Kharis

Hi Kharis,

Thanks for the response. I used the first code you recommended but it put an extra line at the top with UK telephone numbers and a button for support?!? Please could you update with the correct code?

Thanks
Nicki

Hello Nicki,

Please put back the code to let me inspecting it directly, so I can suggest the better way to resolve it with custom CSS code.

Regards,
Kharis

function moesia_nav_bar() {

?&gt;

&lt;div class="ah-widget-area" style="background-color:#ffffff; color:#000000"&gt;&lt;div class="container"&gt;&lt;aside id="text-4" class="widget widget_text"&gt;			&lt;div class="textwidget"&gt;London:&nbsp; +44 (0) 2074023300  Milton Keynes: &nbsp;+44 (0)1908888388     
<a href="http://google.com">Need Support?</a>&lt;/div&gt;
		&lt;/aside&gt;&lt;/div&gt;&lt;/div&gt;

&lt;?php
echo '&lt;div class="top-bar"&gt;
		&lt;div class="container"&gt;
			&lt;div class="site-branding col-md-4"&gt;';
			if ( get_theme_mod('site_logo') ) :
				echo '&lt;a href="' . esc_url( home_url( '/' ) ) . '" title="';
					bloginfo('name');
				echo '"&gt;&lt;h1 style="margin:0;"&gt;&lt;img class="site-logo" src="' . esc_url(get_theme_mod('site_logo')) . '" alt="';
					bloginfo('name');
				echo '" /&gt;&lt;/h1&gt;</a>';
			else :
				echo '&lt;h1 class="site-title"&gt;<a href="' . esc_url( home_url( '/' ) ) . '" rel="home">';
					bloginfo( 'name' );
				echo '</a>&lt;/h1&gt;';
				echo '&lt;h2 class="site-description"&gt;';
					bloginfo( 'description' );
				echo '&lt;/h2&gt;';
			endif;
		echo '&lt;/div&gt;';
		echo '&lt;button class="menu-toggle btn"&gt;&lt;i class="fa fa-bars"&gt;&lt;/i&gt;&lt;/button&gt;
			&lt;nav id="site-navigation" class="main-navigation col-md-8" role="navigation"&gt;';
			wp_nav_menu( array( 'theme_location' =&gt; 'primary' ) );
		echo '&lt;/nav&gt;';

		if ( get_theme_mod('toggle_search', 0) ) :
			echo '&lt;span class="nav-search"&gt;&lt;i class="fa fa-search"&gt;&lt;/i&gt;&lt;/span&gt;';
			echo '&lt;span class="nav-deco"&gt;&lt;/span&gt;';
			echo '&lt;div class="nav-search-box"&gt;';
				get_search_form();
			echo '&lt;/div&gt;';
		endif;
	echo '&lt;/div&gt;';
echo '&lt;/div&gt;';

}

Hello there,

I still can’t find that element on your site URL you shared. Is it in your other site?

Regards,
Kharis

Sorry, I had deactivated it as I did not want the telephone numbers showing. I have reactivated it now.

Thanks
Nicki

You might not believe this, but it looks fine to me as seen on below screenshot.

Cloudup

Am I missing something? Please advise.

Could you please take a screenshot and share it to cloudup.com?

Regards,
Kharis

It was the phone numbers at the top that i didnt want but i’ve figured out how to delete them…thanks :slight_smile: Just being a bit slow on a Friday afternoon :wink:

Excellent! I am glad to hear you figured that out.

Feel free to open an new topic if you need anything else.

It is Saturday morning already here. I am in Asia. Have a wonderful Friday afternoon to you!

Regards,
Kharis

OK, its worked now but there is no text (just an image) for h1. I wanted to add some meaningful text as h1 (and ideally h2 as well) on the front page.

thanks
nicki

Hello Nicki,

If I am not wrong, the H1 tag should be placed at the top of your page. See this article for your reference. The reason why I suggested to attached it to the image logo is it displays on your all pages, so you don’t have to rewrite it.

To add a text inside it, try to replace this:


<h1 style="margin:0;">

with:


<h1 style="margin:0;"><span style="display:none;">Your text goes here</span>

Once you’re done, you can analyze your heading tags with this tool.

Regards,
Kharis

Hi,

Since my site title is a picture, can I change the header title to H1 instead?

Best,
Linda

oh wait, apologies - let me try your suggested as above Kharis.

Just realised Nicky asked the same question.