Add "Advertisement" into the Custom ad units

Posted in: Newspaper
Post count: 23

I was wondering how to add the word “Advertisement” into the Custom ad units so it appears exactly the same as the normal ad units.

It would be great if we could have this as an option like in the normal ad units.

Post count: 22421

Hello,

You can add this html code in the ad spot before your add:
<span class="td-adspot-title">Advertisment</span>
Here is an example: https://www.screencast.com/t/uTL4gR2n

Thank you!

Post count: 23

Thanks Bogdan.

That seemed to work for non-adsense ads, but for Adsense ads it doesn’t show.

This is an example of the code I put in Custom ad 1

<span class=”td-adspot-title”>Advertisment</span>
<script async src=”//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js”></script>
<!– Desktop Footer Responsive –>
<ins class=”adsbygoogle”
style=”display:block”
data-ad-client=”ca-pub-xxxxxxxxxxxxxx”
data-ad-slot=”8388084206″
data-ad-format=”auto”></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>

Any idea why it’s not working?

Post count: 22421

OK, An easier way to do it is simply type in your ad title in the custom ad box element in visual composer: https://www.screencast.com/t/f2auiE4gZQ
How are you implementing the custom ad? If you use an ad box, there is a title field.

Thank you!

Post count: 23

Which “page” do I do this for in the visual composer as I don’t see a default page?

I am implementing it by inserting the code in the loop file as I need the ads to appear in particular places that aren’t in the template.

Post count: 20688

Hi,

You can do something like this, add an Ad box element on a page and configure it with an adspot and a title – https://www.screencast.com/t/zlQpfrAdq then use this ad box shortcode in your loop file – https://www.screencast.com/t/SNNZCjK9cg like this example here – https://www.screencast.com/t/DjGSSr3t1 The result is this – https://www.screencast.com/t/bqELNIlasQ6O Also remove the span tags if you added them previously, from the ad code.

Thanks

Post count: 23

How do I get into this place https://www.screencast.com/t/zlQpfrAdq as I thought visual composer was only for pages, and as the default template isn’t an actual page I don’t know how to do it.

Thanks

Post count: 20688

Hi,

That is a simple page I created in Visual composer – https://www.screencast.com/t/R421IGscrrfv in which I inserted an Ad box element then set an adspot and a title – https://www.screencast.com/t/Os3b1iHh After that you can use this ad box code in your do_shortcode – https://www.screencast.com/t/i66u24neemhttps://www.screencast.com/t/LljjINnxTcq You can use a different custom ad if you want.

Thanks

Post count: 23

But visual composer is just for ‘pages’ and as the post template isn’t a ‘page’ how do I get into Visual composer for it?

Post count: 20688

Hi,

Maybe I am misunderstanding what you were asking. I believe you wanted to have an ad title on a custom ad that you are going to manually insert in the structure of the loop single file corresponding to the post template – https://www.screencast.com/t/5f6s5Rs1 with a code like this example and this result – https://www.screencast.com/t/1Oum1O8l

<?php echo do_shortcode ('[td_block_ad_box spot_id="custom_ad_1" spot_title="ad title" tdc_css=""]'); ?>

Thanks

Post count: 23

Worked perfect, thanks 🙂

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