Currently I'm building an ajax site, this code below displays an ad on a singular page although I have broken it up into different segments, this way I could place multiple ads on multiple pages, one problem is the width seems a bit off, so my questions are, can I modify the CSS to display the ad correctly and is this legal?

Within head of index

<script src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script> 

Within page in main body

<div class="ads">
<ins class="adsbygoogle"
     style="display:inline-block;width:728px;height:90px"
     data-ad-client="xxxxx"
     data-ad-slot="xxxxxx"></ins>
</div>

Within js file

function displayGoogleAds(){
    $('ins').each(function(){
        (adsbygoogle = window.adsbygoogle || []).push({});
    });
}
	$( document ).ajaxComplete(displayGoogleAds);
	
    12 days later

    Hi, I don't know entirely about your topic but it's better to work on the recommendation provided by the ad-publisher company.

      Write a Reply...