Banner placement for home page seperate from all other posts & pages

Posted in: Newspaper
Post count: 113

Hi Guys,

I need to set a billboard banner (960×300) for the home page but then another in the same position for the rest of the site.

How to I go about this?

David

Post count: 23312

Hello David Henry,

Please provide some useful screenshots where to exemplify what you want to get. Also, you should provide your website URL so we can further inspect it closer.

Thanks.

Post count: 113

Thanks Catalin,

You can see the position that I need it on here:
https://hungry-cause.flywheelsites.com/

It’s the part at the top that currently says “ROS Leader” which is the holding area until the ads are being severed. here’s a link to a screen of the area: http://i.share.pho.to/c256536e_o.png

Between the Menu and the Ticker it’s a light grey box, it’s currently hard coded into header-style-1.php.

I think that there are many ways to do this but what’s the best option that will allow us to update the theme without breaking it?

David

Post count: 23312

Hello David Henry,

If you want to make some changes to your header style you should use the child theme because you will not lose this customization on the next update. For more information about child theme support, please check here -> https://forum.tagdiv.com/the-child-theme-support-tutorial/

Thanks for your message!

Post count: 113

Thanks Catalin, I know how to do that.

What I need to know here is if it’s possible to have a banner placement on the home page that’s not part of any other page. E.G. I have 1 banner position, then assign a banner on the home page, then another for the rest of the site.

Above I gave a screen grab of where the banners should appear.

Maybe the best approach is something like:

If home page=yes, then display X banner code, if home page=no, then display Y banner code.

If this is possible I can add it to the header-style-1.php file in the child theme.

Does this make sense?

David

Post count: 23312

Hello Henry,

Unfortunately, our theme does not have any such an option but notice that you can do this from the code if you will add a condition like this -> if (is_front_page()), according to this useful guide here -> https://developer.wordpress.org/reference/functions/is_home/ This change should have to be done in ads.php, like this -> https://www.screencast.com/t/Dowr7VoGIP8K
Another solution, in this case, would be to use AdRotate plugin

Hope this helps!

Thanks for the message!

Viewing 6 posts - 1 through 6 (of 6 total)
The forum ‘Newspaper’ is closed to new topics and replies.