Information:
MSB Default Theme by Nichemate.com

Tags Used:
[adblock1] used in the sidebar


Code Snippets:
The following code snippet can be used to show adsense to search engine traffic and/or show affilate banner ads otherwise.
1. Paste the code snippet into one of the adblock tags in MSB.
2. Edit the CSS styling by changing the height and width on line 3 of the snippet. 
3. Insert your adsense codes and affiliate banner codes into the suitable sections in the snippet.




<? $searchtraffic = preg_match('/^http:\/\/(\w+\.)?(google|msn|live|yahoo|aol|altavista|ask|cnn|alexa|scour|cuil)\./',$_SERVER['HTTP_REFERER']); 
if ((($showad == 1) && ($searchtraffic == 1)) OR ($showaff == 1)) { ?>
<div style="width:250px; height:250px; float:left;">
<? }
if (($showad == 1) && ($searchtraffic == 1)) {    
      ?>YOUR ADSENSE CODE HERE<?
   }
if ((($searchtraffic == 0) && ($showad == 1) && ($showaff == 1)) OR (($showad == 0) && ($showaff == 1))) {
      ?>YOUR AFFILIATE BANNER CODE HERE<? 
}
if (($showad == 1) OR ($showaff == 1)) { ?>
</div>
<? } ?>