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 :
- Open your WP plugin editor from WP Admin.
- Edit “quick-adsense.php” file.
- Find this line : $adsalign = get_option(‘AdsAlign’.$adn);
- 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; } }
- Click "Update File" button.
That's it. Your ads should be aligned randomly now 😀
Leave a Reply