I have placed Google in-article ad code in Single Post Content / Ads boxes but no ads are appearing, just the “Advertisement” title.
Placement of Google display code in an ad box top of sidebar does work, however.
Please see both phenomena here: https://jazzjournal.co.uk/2020/05/25/wynton-kelly-someday-my-prince-will-come/
Can you help?
Thanks
MG
Further to this, the same Google code works fine in Theme Panel ad spaces. So the code is active and good. Can Google code not work in Single Post Templates? I have spent many hours laboriously customising a template in order to be able to place ads better than in the themes Style 1 but it doesn’t seem so easy…
Ok, I have fixed this by enclosing Google code within
<div style=”width:320px”>
</div>
as you advise in another forum reply.
Thanks
MG
Further to this, Calin, you say in this post – https://forum.tagdiv.com/topic/single-page-template-google-adsense-not-displaying/
“Please make a test, set the code in a div with a width for inline ads and check the results.
-> https://i.imgur.com/421qX6d.png
<div style=”width:320px”>
<div>
If is working, set the width to auto or 100%”
[<div> should be </div>]
Two questions:
1) Is 320px true for all users
2) Where is “set the width to auto or 100%”? I can’t see any option to set width in Single Post Content/Ads
Just want to make sure I have correct, universal message for all users here.
Thanks
MG
Hi,
Indeed the ads set in Single Post Content must be declare the width, unfortunately for the moment there is no option for this and the code need to be set manually.
1. You can set the width in px ( 32px, 720px what width you want your ads to be), in some cases you can use width auto, and the ads will take the form that will be best to be display or you can set the width 100% to display the ad on full width of the content where the ad is set, unfortunately the auto and 100% is not working for all users.
If you have some questions or there is something that you do not understand, let me know!
Thank you!
You haven’t answered 2) Where is “set the width to auto or 100%”? I can’t see any option to set width in Single Post Content/Ads
Do you mean in the CSS tab?
Or do you mean add “auto” or “100%” to the ad code? If so, where?
Please be explicit.
For a moment one of my ads appeared in Single Post Content but mostly they don’t. Why? Here is an example – div tags are correct, yes?
<div style=”width:320px”>
<script async src=”https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js”></script>
<!– JJ display 1 –>
<ins class=”adsbygoogle”
style=”display:block”
data-ad-client=”ca-pub-7426344127145001″
data-ad-slot=”3267840445″
data-ad-format=”auto”
data-full-width-responsive=”true”></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
</div>
Hi Mark Gilbert,
2. Usually the ads have set a code for format and this is in most cases set on auto, like in you case https://i.imgur.com/L98UBkM.png
Using <div style=”width:320px”> you just change the width allocate for the ads and it will try to find some ads that are fits to the new space from div.
Thank you!
Are you saying I don’t need any div tags if ad code is auto? A lot of guidance (a manual, an updated ad guide page from Newspaper?) is needed here. I am spending hours doing a survey of various ad placements and will report in spreadsheet. Content is suffering needless to say. So much for easy Newspaper and editors get on with the content or some such Newspaper promotional slogan…
