-
AbsaWeb
Hello,
In a previous topic you told me to do the following to add a link to the header.
To add a link to your Header, I would recommend the following steps:
1. Create a Block Element – Site Header. https://docs.generatepress.com/article/block-element-site-header/
2. Add a Container Block. Reference: https://docs.generateblocks.com/article/container-overview/
3. Add a link through the Toolbar.
4. Add your Background Image: https://docs.generateblocks.com/article/backgrounds-options-overview/
All this is correct and works, but even if I add the header tag (<header …. ) in the html it is not displayed.
You can see it in the example that I give you privately. Thank you.
-
Hi there,
I am not sure what you’re trying to achieve.
Do you have an example of what you want to do ? -
AbsaWeb
If I follow the instructions that you gave me in another topic and I have given you above, the html code is the following:
<a class="gb-container gb-container-955d5844" href="https://www.example.com" rel="home" aria-label="cabecera"></a>All this even if I mark the block as header tag.
In the example that I have given you privately you can see it.
Therefore, it does not have the correct format, which is the following:
<header class="site-header" id="masthead" aria-label="Sitio" itemtype="https://schema.org/WPHeader" itemscope=""> <div class="inside-header"> </div> </header>The first topic is this:
https://generate.support/topic/link-to-home-in-header/
Thank you !
-
You need to choose the hidden link instead of wrapper for the link type.
-
AbsaWeb
But that doesn’t solve the problem.
The issue is that if I use a block in the header, I don’t get the header tag.
Please, can you see the example that I have sent you privately?
Thank you.
-
1. Edit the Container and:
1.1 remove the container link.
1.2 set the Layout > Position toRelative2. inside the Container add Button with the Link and the Attributes you require.
2.1 Give the Button an Advanced > Additional CSS Class of:container-linkOnce thats done let me know, and we can provide some CSS to make the link fill the Container.
-
AbsaWeb
Hello,
But what button?
I just wanted to be able to link the background of the header image to the home page.
Can you please read this topic?
https://generate.support/topic/link-to-home-in-header/
What happens is that although marking that it is a header tag, it is not shown as such, but one more block.
Like this, with your <header and itemprop…etc
<header class="site-header" id="masthead" aria-label="Sitio" itemtype="https://schema.org/WPHeader" itemscope=""> <div class="inside-header"> </div> </header>With GB is ike this:
<a class="gb-container gb-container-955d5844" href="https://www.example.com" rel="home" aria-label="cabecera"></a>Thanks.
-
The issue is that if I use a block in the header, I don’t get the header tag.
Have you tried this? In order to have the header tag, you need to do this:
You need to choose the hidden link instead of wrapper for the link type. -
AbsaWeb
Sorry, but I choose hidden link and the problem is the same.
Can you see the example I sent you privately?
Thanks.
-
Fernando
Hi there,
This is what I’m seeing from my end: https://share.getcloudapp.com/wbuLnQoA
It’s already a
<header>. Is that what you’re going for or something else? -
AbsaWeb
Ok, thanks !
-
Fernando
You’re welcome!
- You must be logged in to reply to this topic.