public function settings($settings)
 {
     $settings['fes_pu_settings'] = array('id' => 'fes_pu_settings', 'name' => '<strong>' . __('FES Product Updates', 'edd-fes-product-updates') . '</strong>', 'desc' => __('Configure the options for FES Product Updates', 'edd-fes-product-updates'), 'type' => 'header');
     $settings['fes_pu_default_footer'] = array('id' => 'fes_pu_default_footer', 'name' => __('Default Email Footer Content', 'edd-fes-product-updates'), 'desc' => __('Content entered here will be automatically appended to the bottom of emails created by vendors', 'edd-fes-product-updates'), 'type' => 'textarea');
     $settings['fes_pu_tags'] = array('id' => 'fes_pu_tags', 'name' => __('Email Tags', 'edd-fes-product-updates'), 'desc' => __('Select the email tags that are shown to vendors as options', 'edd-fes-product-updates'), 'type' => 'multicheck', 'options' => edd_fes_pu_get_email_tags());
     return $settings;
 }
Пример #2
0
function edd_fes_pu_get_enabled_email_tags()
{
    $tags = edd_fes_pu_get_email_tags();
    $enabled = edd_get_option('fes_pu_tags', array());
    foreach ($tags as $key => $tag) {
        if (!array_key_exists($key, $enabled)) {
            unset($tags[$key]);
        }
    }
    return $tags;
}