Costum ad

Posted in: Newspaper
Post count: 42

Hi,

Is posible to add more costum ads? Right now we have 5 costum ad, can i make 10 costum ad?

Thank You

Post count: 20688

Hi,

If you want to add more custom ad spots, you will have to edit the td_config.php
https://www.screencast.com/t/qW11XA2B
And register your new custom ad code in two places, like this
http://screencast.com/t/drqt26uCI

Thanks

Post count: 45

I applied the advice above and added more custom ads using child theme on NewsMag but I am not seeing the effect.

Post count: 20688

Hi,


@nkodgh
You must edit the mentioned theme file directly. The only files that are currently supported through a child theme are mentioned here – https://forum.tagdiv.com/the-child-theme-support-tutorial/

Thanks

Post count: 12

Hi, it works OK, but what if I update the theme, I guess I would have to change the td_config.php before updating.

Thanks

Post count: 20688

Hi,

If you update the theme you will loose the changes made to the theme files directly. In each updated theme package there is a patch folder, where you can see what files have been modified in the update
https://forum.tagdiv.com/whats-included/
That is useful in some cases, when you can update the theme by replacing only the modified files.

Thanks

Post count: 10

Hi there

I also want to add more custom ad spots to my site in the td_config.php file, and have added the code in two places as suggested in both these screen shots. https://www.screencast.com/t/qW11XA2B & http://www.screencast.com/t/drqt26uCI but it’s breaking the site completely. what am I doing wrong?

I have no idea what I am doing wrong, I have tried it a few times and keeps breaking the site.
– – –
this is what I have added
td_api_ad::add(‘custom_ad_6’,
array(
‘text’ => ‘Custom ad 6’,
‘ad_type’ => ‘ajax’,
‘fields’ => array(
‘ad_field_title’ => false,
‘ad_field_position_content’ => false,
‘ad_field_after_paragraph’ => false,
),
)
);

& this code last line of code to register the spot
‘custom_ad_5’ => ‘custom_ad_5’,
‘custom_ad_6’ => ‘custom_ad_6’
),

What am I doing wrong?

Post count: 20688

Hi,

It could mean that you are forgetting a syntax element or there is a mistake in the code you are adding. This modification will not break the website functionality if done properly.
Copy the previous ad code
https://www.screencast.com/t/w0XBpqz45MD
And only change the number of the ad in the code
https://www.screencast.com/t/aj913J6u
Then make the next addition as shown in the screenshot
https://www.screencast.com/t/I1EYGoSbk
https://www.screencast.com/t/XHjBpJqUA6
Double check the code and see if it is done properly. If removing the modifications do not cause problems, then it could mean that maybe you are not doing it right.

Thanks

Post count: 51

Hi there,

I followed all the steps (I added the code into Newsmag parent theme), but the ad spot isn’t showing up. You can see the issue here: http://imgur.com/a/4Gu0R (or live: https://arenarubronegra.com).

Regards!

Post count: 20688

Hi,

It seems to be present in the page structure
https://www.screencast.com/t/ohTizBL2pvQ
If you are using an Adsense ad code check the settings maybe it is disabled
https://www.screencast.com/t/lxklIuqTCu6r
The options should be disabled. Or maybe test with a different ad code, or enter some other content (even random text) and see if it is displayed. Make some tests on a test page with this custom ad.
Clear any caching installed as well after making changes.

Thanks

Post count: 51

Hi Simion,

I discovered where was the issue: the desktop ad size into theme panel. So, I’d should set it there and the ad showed up.

However, this is strange because my ad is resposible by Adsense. I expected the theme could adjust it automatically.

Thanks!

Post count: 20688

Hi,

If it set to Auto, then the proper size of the Adsense ad should be displayed automatically by the theme
https://forum.tagdiv.com/ads-adsense-overview/

Thanks

Post count: 3

Hi,

Is it still possible now to add more custom ad spots in theme panel?? if yes how?? (The screenshots are not working as it’s way too old). Thanks in advance.

Post count: 27744

Hi,

You can set the ads in Single Post Template from tagDiv Cloud Library and you can set top ad, 3 inline ads set after x paragraphs, and bottom ad; please check this article -> https://forum.tagdiv.com/article-ads/ and video https://www.youtube.com/watch?v=biTpVVlr8j8

Thank you!

Post count: 3

Hi Anamaria,

I know about the custom ad placements via Composer/Cloud library. It’s not about the posts. My query is regarding adding more custom ad spots in theme panel via API/child theme. Hope you got my point. You may refer to this support trail for what I’m asking for.

Post count: 27744

Hi,

This will not be implemented. The ads from the theme panel are for standard templates. You can use the ad box element https://forum.tagdiv.com/ads-adsense-overview/, and you can add how many ads you want on the website.

Thank you!

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