Site logo

Archived topic

Problem with ads when Columns enabled

5 replies · Started by Jericho on July 28, 2018

Viewing posts 1–6 of 6

Hi GP Team,

I like to use the column option for my blog. Usually, I put AdSense in-between posts.

Then I have this problem: https://prnt.sc/kc2tuh

Do you guys have a hack/solution so that the ads will fit when masonry grid is checked?

Thanks!

Hmm, masonry itself would need to know about the ads if they're within the posts.

How are you inserting them between posts?

Hi Tom,

I'm using a plugin called Ad Inserter (https://wordpress.org/plugins/ad-inserter/) with the setup of automatic insertion Between Posts. Ads will appear after 1 and 4 posts in Homepage, Category, Tags, and Search pages.

It works fine when using the default blog setup. I hope you can make it work in a masonry grid setup. :)

Thanks!

Is it possible to wrap your ads in specific HTML?

If so, try inserting it like this:

<article class="post type-post generate-columns tablet-grid-50 mobile-grid-100 grid-parent grid-50 masonry-post">
    Your ad in here.
</article>

Hi Tom,

It worked! :)

Thanks very much!

You're welcome :)

This archived topic is closed to new replies.