Advertise inside a Repeating Group

Inside my site I have a page that shows all the User’s friends inside a RG. I initially broke it up into two RGs so I could place an Advertisement spot after the #4 friend.

Was wondering if there is a way to place the Ad directly into the RG? For example, I could have and Ad show up in the #5 spot and the #12.



need to use the repeating groups index…which is just a number. Create more than one group to place into the first cell of repeating group. put a conditional on the group that is the advert to be visible when current cells index is #5 or #12

You could add a group into the first cell of the RG, right below the elements that display data about friend. This means increasing every cell’s height by the height of the ad space.

The group for the ad should have the option “collapse height when hidden” checked and “This element is visible on page load” unchecked.

Then, a condition should say something like: When Current cell's index is 4: This group is visible.

Now, to give the impression that the ad is not in the same cell then friend #4, you can design the ad group with borders that mimic the design of the RG (if you have). To the eye the group will seems in its own cell.

You can put whatever content you need in the group.


@julienallard1 is there a way that you know of, or if it is even needed to make sure the “friend” from index #4 is not skipped over?

I haven’t actually implemented this in my app, so not sure if the data that would normally be displayed in that cell would get “overwritten” or skipped because of the advert group getting shown.

What I’m suggesting above does not hide any friends. Every friends are shown, except that on cell #4, the cell will be extended to also display an ad.

Ok, so in cell #4 they would see the friend and below that see the advert.

But this won’t affect all the cells height on page view because

Sounds like a much better approach than my suggestion as I believe my suggestion would unintentionally “hide” the friend from cell 4 and in place display the advert.

Thanks for the tip.

exactly… cells can have different heights once rendered.

1 Like

Thank You! Thank You!

Nice solution with the hiding group!

If you use the modulo function on the index it would even show every Xth ad.


This topic was automatically closed after 70 days. New replies are no longer allowed.