Comment on SEO AdSense WordPress Theme by Erik.

AdSense Publisher ID Sorry Dave, I actually meant Tags and Categories pages–I had the Super Comments pages in mind as well, but I’ve got a separate ad code for that inserted in the single-2.php file which is how you advised me to do it previously.

My fault for the confusion on that.

I’m basically trying to do something similar to what you explained to me last year on Stallion 7 in this comment thread: https://stallion-theme.co.uk/adsense-wordpress-theme/comment-page-2/#comment-17673

To clarify, I only want the in-text ad to show on Tags and Categories pages (not main page, single posts/pages, etc.). I was able to achieve this previously using a text widget and the ad code as you suggested before, combined with the show/hide function on the text widget.

And this method seems to still work for non-responsive ad code, but not for responsive code.

I tested method 2 (“second scenario” in your previous comment above), using just the text widget and code from my Adsense account. I created both a “regular” non-responsive ad unit and a responsive unit to test it.

It works just fine for a “regular” adsense unit–displays it, and I can hide/show it on any selected pages using the text widget controls.

However it does not work for me when using a responsive unit in a text widget. It does not even display the ad. This is the code I am using(with my adsense pub number removed):

code removed by WordPress…

Again this is on a clean install so I have made no changes that might affect this. I have not added any CSS classes such as the ones you suggest that might affect or hide things in the way you describe. So I am puzzled why this works for a normal non-responsive but not a responsive ad unit.

Thanks for looking into this in such detail.

Erik