Latest

Adding or Removing Ads from the Categorised Posts in Lantro UI v2.0

Thumbnail
Info! You can easily control ads inside categorized posts by editing a single block in your Blogger widget.

In the categorized posts widget, ads are placed after each category section. This is done using a block called category-ad.

Structure Overview

Each category section contains:

  • Category title
  • Posts container (ctgC)
  • Ad block (category-ad)

Default Ad Code

<div class='category-ad' style='margin:30px 0;text-align:center'>
  <div class='dumAd' data-text='Advertisement'/>
</div>

Adding Ads

To show real ads, replace the dummy ad inside the category-ad block with your ad code.

<div class='category-ad' style='margin:30px 0;text-align:center'>

  <ins class="adsbygoogle"
       style="display:block"
       data-ad-client="ca-pub-XXXXXXXX"
       data-ad-slot="XXXXXXXX"
       data-ad-format="auto"></ins>

  <script>
    (adsbygoogle = window.adsbygoogle || []).push({});
  </script>

</div>
Success! Ads will now appear between each category section.

Removing Ads

To remove ads completely, you need to delete the entire category-ad block from your widget.

Before Removing

<div class='ctgW'>

  <h2 class='title'><data:i/></h2>

  <div class='ctgC' expr:data-label='data:i' expr:id='"cId"+data:c'></div>

  <div class='category-ad'>
    <div class='dumAd' data-text='Advertisement'/>
  </div>

</div>

After Removing

<div class='ctgW'>

  <h2 class='title'><data:i/></h2>

  <div class='ctgC' expr:data-label='data:i' expr:id='"cId"+data:c'></div>

</div>
  • Find the category-ad block inside each category.
  • Select from opening <div> to closing </div>.
  • Delete it completely.
Warning! Do not remove ctgC or b:loop — they are required to load posts.
Hi, I’m Shiva E S — the creator of Coshix. I enjoy building websites, and sharing simple tutorials that help people solve real problems easily.

Instagram · GitHub