Google Adsense Ad Code For WordPress Amp Pages :
<amp-ad width=350 height=100
- Replace The pub id with your publisher id.
- Replace Ad Slot with your slot id.
The ad code will help you to show ads on amp pages without any blocking issues. You can show adsense ads in your amp pages by following below procedures.
Display Adsense Ads On WordPress Amp Pages :
- Goto wordpress plugin editor page.
- Select google amp plugin and open it.
- Navigate to amp/templates/single.php
- Then find the <div class=”amp-wp-content”> in webpage by using ctrl+f
- Paste your adsense google amp page ads code below the line.
- Then search do_action( ‘amp_post_template_footer’, $this ); and paste your amp ad code. Before beginning php open tag.
That’s all. Now save the file and confirm. Enjoy google adsense ads in wordpress amp pages. Now your blog earnings never decrease by using google amp in your wordpress sites.