Site logo

Archived topic

Display a link on the Home page under the Footer

13 replies · Started by Stephen on July 29, 2018

Viewing posts 1–14 of 14

Hi,

I would like to display a text link only on the site Home page under the footer area.

Is this best achieved with hooks or is there another way to do it?

I'm using a child theme.

Thanks
Steve

Hi Steve,

You could add the link to the Copyright field in the Footer, it accepts HTML.
Or you could add it in the After Footer Content Hook e.g.

<div class="site-info"><a href="url">My link</a></div>

The site-info class will style it the same as your copyright :)

Hi David,

I want the link to appear below the footer so I need to add a hook. I read the hook should go in the functions file in the child theme. How do I inform the theme to only apply the hook to the Home page?

Thanks
Steve

Thanks David.

Looks great, I will try that and break everything ;-)

I'll post back when everything goes wrong :)

Steve

Haha - sounds like my kind of learning :)

Hi David,

I used an Element to insert a hook under the site footer for my text, but unfortunately the new text/link and hook area do not follow the themes settings i.e. font, link or page bg colour. The hook bg area is grey and the font to large.

How do I resolve this issue please and where do I insert the code, in the CSS file or in the Element Edit window?

Thanks
Steve

Hi again,

I should mentioned I'm using Elementor and GP Pro.

Thanks

Hi there,

are you able to add it to the site so i can have a look and provide the solution?
You can just add the link into the copyright bar..... just separate the copyright and link with a <br> tag to create a new line. Let me know.

Hi David,

I did have the text/link in the copyright area but unfortunately that then shows on all pages. I just want the link on the Home page.

I've added the text/link, thank you.

Steve

BTW, I'm using a child theme.

On a side note, I've been watching videos, reading and playing with Elements all day. Elements is quite simply amazing.................

Aah understood, yes Elements is something very special :)

So add this HTML to your hook:

<div class="site-info">
    <div class="inside-site-info grid-container grid-parent">
        Add your text / HTML here
    </div>
</div>

This will use the same styling as the Site-info

Thanks David.

That worked for the text :) The text was aligned centre and the same size font as the footer copyright. However, when I made the text into a link the text disappeared. A quick visit into the customiser - colour - footer and all is well.

Thank you very much :)

We didn't break anything ;-)

Awesome :) Glad i could help

This archived topic is closed to new replies.