html - Auto-sizing google adsense code on php site -


i have php site. have been given code auto-sizing ad google adsense. have put within "div" align it, , have created function echo adsense code within php script;

<html>     <head>         <title>my website</title>         <link rel="stylesheet" type="text/css" href="main.css" />     </head>     <body>         <?php include("title.php"); ?>           <?php         $googleadsensecode = '  //a function adsense code.           <div align="center"> //<div> align ad.         <script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>         <!-- responsive_textndisplay_20160127 -->         <ins class="adsbygoogle"         style="display:block"         data-ad-client="ca-pub-9232383262111727"         data-ad-slot="4287484293"         data-ad-format="auto"></ins>         <script>         (adsbygoogle = window.adsbygoogle || []).push({});         </script>         </div>';         echo $googeladsensecode;     </body> </html> 

however ad taking whole page, , presumably not picking on remaining website's content.

what error in code or approach?


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -