Fixing problems with AdRotate showing all ads at once
I use an AMP plugin to improve the reading options for my website on Mobile, and to improve overall performance. To support the website, I use adverts. In order to make the best of both worlds, I provide these adverts one at a time on a rotation so that I get an acceptable level of performance whilst still serving adverts.
I encountered a problem recently however, that after troubleshooting I found a cause and want to share my findings. Hopefully this will help develop a fix for it, or at least some understanding to identify what is causing the problems.
When I was providing adverts through adrotate on my website, it’s all served via a group.
A change was done recently on my site however, and I noticed that all the adverts were being served at once. As you can imagine, on sites with thousands of adverts, this could cause some serious problems. Luckily, mine didn’t have that many so I was able to do some testing.
The problem I experienced, was that all adverts from AdRotate were being loaded in the side bar at the same time, rather than one at a time.
I haven’t been to find a solution to this problem, but I at least have a workaround, so wanted to provide my findings, so that it helps others when it comes to troubleshooting, or if they have this problem.
The problem, was caused due to compatibility (or perhaps loading / display issues) with my AMP plugin.
For reference I use the following theme / plugins
- AMP Plugin : Official AMP plugin (current version at time of this post is 2.1.3)
- Theme : Neve
- Ad Plugin : AdRotate
Now, the site had been working previously (only displaying 1 ad per rotation) so I wasn’t sure why it was broken. I did some thinking, and remembered I did a change to my AMP plugin after I updated the website to use https. I was using a “Reader” mode, because at the time my website wasn’t https supported, or AMP supported. So I wanted to ensure maximuum compatibility.
After https:// functionality was added to my website, I updated the plugin to use “Standard” mode.
I did some testing and found out that the adverts load fine (1 at a time rather than all at once) when using “Transitional” mode, but when I use “Standard” mode, it breaks them. It’s not really a solution, merely a workaround for anyone else who is having the same problems and can’t work out why it’s doing this.
It’s possible that maybe I’m not understanding how AMP plugins work, but at least if someone else has the same problem with AdRotate and plugins, they might be able to see what’s causing it.
So, if you have problems with adverts in AdRotate plugin being loaded all at once. If you use an AMP reader plugin, try changing the reading modes and seeing if this helps