Quick Adsense Random Align

Quick Adsense is one of useful WordPress Plugin which can be downloaded here
http://wordpress.org/extend/plugins/quick-adsense/

It can insert ads to your post content automatically.
Here is a hack to make your ads to be aligned randomly left / right AND center / none :

  1. Open your WP plugin editor from WP Admin.
  2. Edit “quick-adsense.php” file.
  3. Find this line : $adsalign = get_option(‘AdsAlign’.$adn);
  4. Add these lines just right below it :
    if ($adsalign == 1 || $adsalign == 3) {
    	$adsalign = mt_rand(1, 100);
    	if ($adsalign <= 50) { $adsalign = 1; } else { $adsalign = 3; }
    } else {
    	$adsalign = mt_rand(1, 100);
    	if ($adsalign <= 50) { $adsalign = 2; } else { $adsalign = 4; }
    }
    
  5. Click "Update File" button.

That's it. Your ads should be aligned randomly now 😀

Comments

One response to “Quick Adsense Random Align”

  1. arif Avatar
    arif

    thax… infonya perlu dicoba semoga earning hari ini bertambah

Leave a Reply

Your email address will not be published. Required fields are marked *