Example #1
0
    //removes commas, spaces and convert to array
    $templates = get_page_templates();
    foreach (array_keys($templates) as $template) {
        $newoptions['show_in_template'][$template] = (int) strip_tags(stripslashes($_POST['show_in_template'][$template]));
    }
}
// Save if there were any changes
if ($options != $newoptions) {
    $options = $newoptions;
    update_option('wp-supersized_options', $options);
    $msg = '<div class="updated"><p><strong>' . __('Your settings have been updated', 'WPSupersized') . '</strong></p></div>';
}
if (isset($_POST['reset_options'])) {
    $newoptions['reset_options'] = 1;
    update_option('wp-supersized_options', $newoptions);
    WPSupersized::install();
    $msg = '<div class="updated"><p><strong>' . __('WP Supersized options are back to default!', 'WPSupersized') . '</strong></p></div>';
}
$options = get_option('wp-supersized_options');
// makes sure we use the latest options (from update or reset)
echo '<div class="wrap">';
echo screen_icon() . '<h2>';
_e('WP Supersized options', 'WPSupersized');
echo '</h2>';
// Paypal donation button
echo '<br />
        <div style="float:right; width:124px; margin-right: 20px;">
        <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=HQ3YVQD2HGFXG&lc=GB&item_name=World%20in%20my%20Eyes&item_number=WP%20Supersized&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donateCC_LG_global%2egif%3aNonHosted"><img src="https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG_global.gif" border="0" alt="PayPal — The safer, easier way to pay online."></a>
        </div>';
echo '<p>';
_e('Visit this <a href="http://www.worldinmyeyes.be/2265/wp-supersized-wordpress-plugin/">plugin homepage</a> for bug reporting or help.', 'WPSupersized');