'', 'ab_dspcnt' => '', 'ab_target' => '', 'ab_adsense' => '', 'ab_adsense_fixed' => '', 'ab_adsense_pos' => '', 'ab_adsense_pubid' => '', 'ab_adsense_channel' => '', 'ab_adsense_corners' => '', 'ab_adsense_col_border' => '', 'ab_adsense_col_title' => '', 'ab_adsense_col_bg' => '', 'ab_adsense_col_txt' => '', 'ab_adsense_col_url' => '', 'ab_nocss' => '', 'ab_width' => '', 'ab_padding' => '', 'ab_nofollow' => '', 'ab_powered' => '', 'ab_yah' => '', 'ab_yourad' => '', 'ab_yaht' => '', 'ab_yahurl' => '', 'ab_fix' => '', 'ab_count' => '' ); $widget_adbuttons_cfg = ad_buttons_get_config(); $ol_flash = ''; // check if the form has been submitted and validate input if( $_SERVER['REQUEST_METHOD'] == 'POST' && current_user_can( 'manage_options' )){ if ( ! isset( $_POST['_abupd'] ) || ! wp_verify_nonce( $_POST['_abupd'], 'update-settings' )) { print 'Sorry, your nonce did not verify.'; exit; } else { // process form data if (is_numeric ($_POST['ab_dspcnt'])) { $widget_adbuttons_cfg['ab_title'] = sanitize_text_field($_POST['ab_title']); $widget_adbuttons_cfg['ab_dspcnt'] = (int)$_POST['ab_dspcnt']; $widget_adbuttons_cfg['ab_target'] = sanitize_text_field($_POST['ab_target']); $widget_adbuttons_cfg['ab_adsense'] = (bool)$_POST['ab_adsense']; $widget_adbuttons_cfg['ab_adsense_fixed'] = 1; $widget_adbuttons_cfg['ab_adsense_pos'] = (int)$_POST['ab_adsense_pos']; if($widget_adbuttons_cfg['ab_adsense_pos'] > $widget_adbuttons_cfg['ab_dspcnt']){ $widget_adbuttons_cfg['ab_adsense_pos'] = $widget_adbuttons_cfg['ab_dspcnt']; } $widget_adbuttons_cfg['ab_adsense_pubid'] = sanitize_text_field($_POST['ab_adsense_pubid']); $widget_adbuttons_cfg['ab_adsense_channel'] = (int)$_POST['ab_adsense_channel']; if (preg_match('/rc:\d{1,2}/', $_POST['ab_adsense_corners']) == 1) $widget_adbuttons_cfg['ab_adsense_corners'] = sanitize_text_field($_POST['ab_adsense_corners']); $widget_adbuttons_cfg['ab_adsense_col_border'] = (int)hexdec(trim($_POST['ab_adsense_col_border'], "#")); $widget_adbuttons_cfg['ab_adsense_col_title'] = (int)hexdec(trim($_POST['ab_adsense_col_title'], "#")); $widget_adbuttons_cfg['ab_adsense_col_bg'] = (int)hexdec(trim($_POST['ab_adsense_col_bg'], "#")); $widget_adbuttons_cfg['ab_adsense_col_txt'] = (int)hexdec(trim($_POST['ab_adsense_col_txt'], "#")); $widget_adbuttons_cfg['ab_adsense_col_url'] = (int)hexdec(trim($_POST['ab_adsense_col_url'], "#")); $widget_adbuttons_cfg['ab_nocss'] = (bool)$_POST['ab_nocss']; $widget_adbuttons_cfg['ab_width'] = (int)$_POST['ab_width']; $widget_adbuttons_cfg['ab_padding'] = (int)$_POST['ab_padding']; $widget_adbuttons_cfg['ab_nofollow'] = (bool)$_POST['ab_nofollow']; $widget_adbuttons_cfg['ab_powered'] = (bool)$_POST['ab_powered']; $widget_adbuttons_cfg['ab_yah'] = (bool)$_POST['ab_yah']; $widget_adbuttons_cfg['ab_yourad'] = (bool)$_POST['ab_yourad']; $widget_adbuttons_cfg['ab_yaht'] = sanitize_text_field($_POST['ab_yaht']); $widget_adbuttons_cfg['ab_yahurl'] = sanitize_text_field($_POST['ab_yahurl']); $widget_adbuttons_cfg['ab_fix'] = (bool)$_POST['ab_fix']; $widget_adbuttons_cfg['ab_count'] = (int)$_POST['ab_count']; update_option('widget_adbuttons_cfg',$widget_adbuttons_cfg); $ol_flash = "Your settings have been saved."; } else { $ab_num_err = 1; } } } ?>

' . $ol_flash . '

'; ?>

Ad Buttons Settings

Number of Ad Buttons to display in the sidebar widget
Ad order > fixed position
When checked, the ads will show in a fixed order. When unchecked, the ads will show in random order
Target attribute for ad links > target "_blank"
> target "_top"
> don't use target attribute
open links in new tab/window
open links in current window
Strict DOCTYPE compatibility
Target attribute for ad links > use nofollow links
When checked, this ads the rel="nofollow" attribute to the Ad Buttons links
Link love > show 'powered by Ad Buttons' link
Show some link love to the author of this plugin. If you need to hide the link, please considerer making a small donation to the Ad Buttons project .
Stats > count views and clicks of logged in users
When unchecked, ad views and clicks of logged in users will not be recorded in the Stats.

Show 'Your Ad Here' button > When checked, this shows a button linking to your advertizing details page
'Your Ad Here' page
or
'Your Ad Here' url
> 0, 'child_of' => 0, 'selected' => $widget_adbuttons_cfg['ab_yourad'], 'echo' => 1, 'name' => 'ab_yourad' ); wp_dropdown_pages($args); ?>
> " size="25" maxlength="200">
The page on your site that contains details about advertizing on your website. This page should contain contact details, website statistics, advertizing plans, etc.

AdSense > enable AdSense this adds one 125 x 125 AdSense ad to your rotating ad pool
AdSense fixed position show the adsense ad always in this ad position
Ad client " size="25" maxlength="25"> your AdSense Publisher ID (pub-xxxxxxxxxxxxxxxx)
Ad channel optional ad channel (needs to be created in your AdSense account first)
AdSense corner style AdSense corner style
AdSense colors
border color
title color
background color
text color
link color
use hex color codes with a lenght of 7 characters
(i.e. #FFFFFF = white, #000000 = black, #0000FF = blue)
preview of your current ad settings:

please remember not to click on your own AdSense ads, this will get you banned from AdSense!

Disable css styling > disable css check to disable below parameters for layout control. With some wordpress themes the layout breaks when using css styling on the ads
Ad block width width of your sidebar
Ad padding size of the padding arround your ads
preview:
'; } } echo'ad button'; $count = $count + 1; } if($widget_adbuttons_cfg['ab_adsense']){ if($widget_adbuttons_cfg['ab_adsense_pos']==$count){ echo '
'; } } ?>