Beispiel #1
0
<?php

/**
 * WIDGETS options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('widgets');
$options_panel->Title(__('Widgets', 'mtt'));
$options_panel->addText('widget_rss_update_timer', array('name' => __('RSS Widget: update timer (in minutes)', 'mtt'), 'desc' => sprintf(__('Default is 12 hours, leave blank for not activating<br />Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/1567/12615')), 'std' => '', 'validate_func' => 'validate_rss_time'));
$options_panel->addCheckbox('widget_meta_slim', array('name' => __('New Meta widget', 'mtt'), 'desc' => __('Based on the original, removes WordPress links and adds a custom link'), 'std' => false));
$options_panel->addCheckbox('widget_hide_description', array('name' => __('Hide widgets descriptions', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('widget_close_first_sidebar', array('name' => __('Make first sidebar closed as default', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('widget_break_title_long_lines', array('name' => __('Force new lines in widgets titles.', 'mtt'), 'desc' => sprintf(__('Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/98598/12615')), 'std' => false));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('REMOVE WIDGETS', 'mtt')));
$widgets_defaults = array('pages' => __('Pages', 'mtt'), 'calendar' => __('Calendar', 'mtt'), 'archives' => __('Archives', 'mtt'), 'links' => __('Links', 'mtt'), 'meta' => __('Meta', 'mtt'), 'search' => __('Search', 'mtt'), 'text' => __('Text', 'mtt'), 'categories' => __('Categories', 'mtt'), 'recent_posts' => __('Recent Posts', 'mtt'), 'recent_comments' => __('Recent Comments', 'mtt'), 'rss' => __('RSS', 'mtt'), 'tag_cloud' => __('Tag Cloud', 'mtt'), 'nav_menu' => __('Custom Menu', 'mtt'));
$non_defaults = isset($this->params['widgets_non_default']) ? $this->params['widgets_non_default'] : array();
$widgets_array = array_merge($widgets_defaults, $non_defaults);
$options_panel->addCheckboxList('widget_remove', $widgets_array, array('name' => '', 'desc' => '', 'class' => 'no-toggle', 'std' => false));
$options_panel->addCheckbox('widget_remove_role', array('name' => __('Remove widgets only for non-administrators', 'mtt'), 'desc' => __('You have to grant edit_theme_options capabilities to your editors for this to work.', 'mtt'), 'std' => false));
$options_panel->CloseTab();
Beispiel #2
0
/**
 * POST LISTING options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('post_listing');
$options_panel->Title(__('Post, Page and Custom Post Types listing', 'mtt'));
/*******************************************************************************
 * GENERAL
 ******************************************************************************/
$options_panel->addCheckbox('postpageslist_persistent_list_view', array('name' => __('Posts: persistent Post listing view', 'mtt'), 'desc' => sprintf(__('If you change the viewing mode (list or excerpt view), it doesn\'t stick. Follow this %s. Tip via: %s.%s', 'mtt'), B5F_MTT_Utils::make_tip_credit('track ticket', 'http://core.trac.wordpress.org/ticket/20335'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/34956/12615'), "<div class='img-help'><img src='{$plugin_url}images/postlisting-persistent.jpg' /></div>"), 'std' => false));
$options_panel->addCheckbox('postpageslist_enable_category_count', array('name' => __('Posts: enable Category count', 'mtt'), 'desc' => sprintf(__('Inspired by: %s.%s', 'mtt'), B5F_MTT_Utils::make_tip_credit('Stack Overflow', 'http://stackoverflow.com/a/15845723/1287812'), "<div class='img-help'><img src='{$plugin_url}images/postlisting-category-count.jpg' /></div>"), 'std' => false));
$options_panel->addCheckbox('postpageslist_template_filter_enable', array('name' => __('Pages: enable filtering by Template', 'mtt'), 'desc' => sprintf(__('Tip via: %s.%s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/12492/12615'), "<div class='img-help'><img src='{$plugin_url}images/postlisting-page-template.jpg' /></div>"), 'std' => false));
$options_panel->addCheckbox('postpageslist_duplicate_del_revisions', array('name' => __('All types: enable Duplicate Post and Delete Revisions', 'mtt'), 'desc' => sprintf(__('Based on: %s.%s', 'mtt'), B5F_MTT_Utils::make_tip_credit('GD Press Tools', 'http://wordpress.org/extend/plugins/gd-press-tools/'), "<div class='img-help'><img src='{$plugin_url}images/postlisting-duplicate-revision.jpg' /></div>"), 'std' => false));
$options_panel->addCheckbox('postpageslist_move_views_row', array('name' => __('Re-position the row action (see description)', 'mtt'), 'desc' => "<div class='img-help'><img src='{$plugin_url}images/postlisting-reposition-action.jpg' /></div>", 'std' => false));
/*******************************************************************************
 * CUSTOM COLUMNS
 ******************************************************************************/
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('CUSTOM COLUMNS', 'mtt')));
$options_panel->addCheckbox('postpageslist_enable_id_column', array('name' => __('All types: add ID column', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addText('postpageslist_title_column_width', array('name' => __('All types: width of the Title column', 'mtt'), 'desc' => __('Sometimes the Title column gets shrinked by other columns, you may change this here. Use px, em or %, i.e. 200px, 50%', 'mtt'), 'std' => '', 'validate_func' => 'validate_css_num_value'));
$Thumbnail_column_fields[] = $options_panel->addText('proportion', array('name' => __('Proportion of the thumbnails', 'mtt'), 'desc' => __('Used for width and height. The scale is proportional, this value is used for the bigger side.', 'mtt'), 'std' => ''), true);
$Thumbnail_column_fields[] = $options_panel->addText('width', array('name' => __('Width of the column', 'mtt'), 'desc' => __('Depending on the proportion you may need this. Use px, em or %, i.e. 200px, 50%', 'mtt'), 'std' => ''), true);
$Thumbnail_column_fields[] = $options_panel->addCheckbox('count', array('name' => __('Show total number of attachments', 'mtt'), 'desc' => sprintf(__('If greater than 1.%s', 'mtt'), "<div class='img-help'><img src='{$plugin_url}images/postlisting-attach-column.jpg' /></div>"), 'std' => false), true);
$options_panel->addCondition('postpageslist_enable_thumb_column', array('name' => __('All types: add Thumbnail column', 'mtt'), 'desc' => __('Shows the featured image or, if not set, the first attached.', 'mtt'), 'fields' => $Thumbnail_column_fields, 'std' => false, 'validate_func' => 'validate_postlisting'));
/*******************************************************************************
 * CONTENT COLORS
 ******************************************************************************/
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('CUSTOM COLORS FOR DIFFENT TYPES OF CONTENT', 'mtt')));
Beispiel #3
0
<?php

/**
 * MEDIA options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('media');
$options_panel->Title(__('Media', 'mtt'));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>%s', __('MEDIA LIBRARY', 'mtt'), "<div class='img-help desc-field'><a href='{$plugin_url}images/media-all.jpg' target='_blank'><img src='{$plugin_url}images/media-all.jpg' style='max-width:100%' /></a></div>"));
$options_panel->addCheckbox('media_image_bigger_thumbs', array('name' => __('Bigger thumbnails in the default column', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('media_image_id_column_enable', array('name' => __('Add ID column', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('media_image_size_column_enable', array('name' => __('Add image size column', 'mtt'), 'desc' => sprintf(__('Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/30894/12615')), 'std' => false));
$options_panel->addCheckbox('media_image_thubms_list_column_enable', array('name' => __('Add a column that lists all thumbnails of the image, with direct link to it.', 'mtt'), 'desc' => sprintf(__('Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/7757/12615')), 'std' => false));
$options_panel->addCheckbox('media_download_link', array('name' => __('Download link in row actions', 'mtt'), 'desc' => sprintf(__('Adds a download link to all items (Edit|Delete|View|Download). Tip via: %s. The difference here is that there is no external script for downloading, it has to be done with a mouse right click and selecting "Save as".', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/30159/12615')), 'std' => false));
$options_panel->addCheckbox('media_better_attachment', array('name' => __('Enables the re-attachment', 'mtt'), 'desc' => sprintf(__('Change the parent of the media file to another post/page<br />Unfortunately, this disables the capability to sort the column... Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WPEngineer', 'http://wpengineer.com/2165/small-extension-for-the-media-library/')), 'std' => false));
$options_panel->addCheckbox('media_camera_exif', array('name' => __('Add Camera Exif info as meta data', 'mtt'), 'desc' => sprintf(__('The camera info will be stored as Custom Fields for image attachments. This will also enable Custom Fields when editing the attachemnt and a column with the information in the Media Library. Tip via: %s.', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/91177/12615')), 'std' => false));
$options_panel->addCheckboxList('media_remove_metaboxes', array('discussion' => __('Discussion', 'mtt'), 'comments' => __('Comments', 'mtt'), 'slug' => __('Slug', 'mtt'), 'author' => __('Author', 'mtt')), array('name' => __('Remove Meta Boxes', 'mtt'), 'desc' => '', 'class' => 'no-toggle', 'std' => false));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('IMAGES UPLOAD', 'mtt')));
// MEDIA LIBRARY 3.5
global $wp_version;
if (version_compare($wp_version, '3.5', '>=')) {
    $options_panel->addCheckbox('media_uploaded_to_this_post', array('name' => __('Make "Uploaded to this post" the default view', 'mtt'), 'desc' => sprintf(__('Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/76213/12615')), 'std' => false));
}
$options_panel->addCheckbox('media_include_extras_sizes', array('name' => __('Include all custom sizes', 'mtt'), 'desc' => sprintf(__('Lists all custom sizes in the Insert Media selector.<br />By default, it only displays <code>Thumbnail | Medium | Large | Full Size</code>. Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('kucrut.org', 'http://kucrut.org/insert-image-with-custom-size-into-post/')), 'std' => false));
$options_panel->addCheckbox('media_sanitize_filename', array('name' => __('Sanitize filename', 'mtt'), 'desc' => sprintf(__('Removes symbols, spaces, latin and other languages characters from uploaded files and gives them "permalink" structure (clean characters, only lowercase and dahes)<br />Code by: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('toscho', 'https://github.com/toscho/Germanix-WordPress-Plugin')), 'std' => false));
$options_panel->addCheckbox('media_jpg_sharpen', array('name' => __('Sharpen resized images (only jpg)', 'mtt'), 'desc' => sprintf(__('Check an <a href="http://i.stack.imgur.com/hkLaX.png" target="_blank">example</a>. . . Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/1567/12615')), 'std' => false));
$options_panel->addText('media_jpg_quality', array('name' => __('Quality of resized Jpegs', 'mtt'), 'desc' => __('From 1 to 100. WordPress default is 90.'), 'std' => '', 'validate_func' => 'validate_jpg_quality'));
$options_panel->CloseTab();
Beispiel #4
0
 * POST EDITING options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('post_editing');
$options_panel->Title(__('Post and Page Editing', 'mtt'));
$options_panel->addCheckbox('postpages_enable_page_excerpts', array('name' => __('Pages: enable Excerpt', 'mtt'), 'desc' => sprintf(__('Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('Smashing Magazine', 'http://wp.smashingmagazine.com/2011/05/10/new-wordpress-power-tips-for-template-developers-and-consultants/')), 'std' => false));
$options_panel->addText('postpages_post_revision', array('name' => __('Posts-Pages: number of revisions to maintain', 'mtt'), 'desc' => __('-1 (unlimited) | 0 (none) | 1 or more (custom)', 'mtt'), 'validate_func' => 'validate_postediting', 'std' => ''));
$options_panel->addText('postpages_post_autosave', array('name' => __('Posts-Pages: auto-save interval <em>in minutes</em>', 'mtt'), 'desc' => '', 'validate_func' => 'validate_postediting', 'std' => ''));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('POST CATEGORIES', 'mtt')));
$options_panel->addCheckbox('postpages_enable_category_count', array('name' => __('Enable count', 'mtt'), 'desc' => sprintf(__('Tip via: %s.%s. Also using CCT option bellow', 'mtt'), B5F_MTT_Utils::make_tip_credit('Stack Overflow', 'http://stackoverflow.com/a/15845723/1287812'), "<div class='img-help'><img src='{$plugin_url}images/postediting-category-count.jpg' /></div>"), 'std' => false));
$options_panel->addCheckbox('postpages_enable_category_fixed', array('name' => __('Category Checklist Tree', 'mtt'), 'desc' => sprintf(__("This is the code from scribu's plugin: %s", 'mtt'), B5F_MTT_Utils::make_tip_credit('Category Checklist Tree', 'http://wordpress.org/plugins/category-checklist-tree/')), 'std' => false));
$options_panel->addCheckbox('postpages_enable_category_noparent', array('name' => __('Disable selection of parent categories', 'mtt'), 'desc' => sprintf(__("Use the previous to use this one. Tip via: %s", 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/58525/12615')), 'std' => false));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>%s', __('PUBLISH META BOX', 'mtt'), "<div class='img-help desc-field'><img src='{$plugin_url}images/postediting-publish-metabox.jpg' /></div>"));
$options_panel->addCheckbox('postpages_move_author_metabox', array('name' => __('Posts-Pages: move the Author metabox into the Publish metabox', 'mtt'), 'desc' => sprintf(__('Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/1567/12615')), 'std' => false));
$options_panel->addCheckbox('postpages_move_comments_metabox', array('name' => __('Posts-Pages: move the Discussion metabox into the Publish metabox', 'mtt'), 'desc' => '', 'std' => false));
//$options_panel->addParagraph(
//    sprintf(
//        '<hr /><h4>%s</h4><p class="desc-field">%s %s</p>',
//        __( 'HIDE FROM PUBLISH METABOX', 'mtt' ),
//        __('Example with Comments and Author moved inside.', 'mtt' ),
//		"<div class='img-help'><img src='{$plugin_url}images/postediting-publish-metabox.jpg' /></div>"
//    )
//);
$options_panel->addCheckboxList('postpages_hide_from_publish', array('status' => __('Status'), 'visibility' => __('Visibility'), 'published' => __('Published On')), array('name' => __('Hide elements'), 'desc' => __('Affects ALL post types. Select items to hide:', 'mtt'), 'class' => 'no-toggle', 'std' => false));
$options_panel->addParagraph(sprintf("<hr /><h4>%s</h4><p class='desc-field'><i>%s</i></p>", __('REMOVE METABOXES : POSTS and PAGES<br />', 'mtt'), __("Although Adminimize can handle this filtering by roles, it only hides the meta box and it doen't removes it from the Screen Options", 'mtt')));
$options_panel->addSelect('postpages_disable_mbox_author', array('none' => 'none', 'post' => 'post', 'page' => 'page', 'post_and_page' => 'post and page'), array('name' => __('AUTHOR', 'mtt'), 'desc' => '', 'class' => 'no-fancy', 'std' => null));
$options_panel->addSelect('postpages_disable_mbox_comment_status', array('none' => 'none', 'post' => 'post', 'page' => 'page', 'post_and_page' => 'post and page'), array('name' => __('DISCUSSION', 'mtt'), 'desc' => '', 'class' => 'no-fancy', 'std' => null));
$options_panel->addSelect('postpages_disable_mbox_comment', array('none' => 'none', 'post' => 'post', 'page' => 'page', 'post_and_page' => 'post and page'), array('name' => __('COMMENTS', 'mtt'), 'desc' => '', 'class' => 'no-fancy', 'std' => null));
$options_panel->addSelect('postpages_disable_mbox_custom_fields', array('none' => 'none', 'post' => 'post', 'page' => 'page', 'post_and_page' => 'post and page'), array('name' => __('CUSTOM FIELDS', 'mtt'), 'desc' => '', 'class' => 'no-fancy', 'std' => null));
Beispiel #5
0
    $bubbles[] = $options_panel->addCheckboxList('cpt', $cpt_list, array('name' => __('Select types:', 'mtt'), 'desc' => '', 'class' => 'no-toggle', 'std' => false), true);
    $bubbles[] = $options_panel->addSelect('status', $cps_list, array('name' => __('Select status:', 'mtt'), 'desc' => '', 'std' => false), true);
    $options_panel->addCondition('admin_menus_bubbles', array('name' => __('Enable', 'mtt'), 'desc' => sprintf(__('Tip via: %s.%s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/95058/12615'), "<div class='img-help'><img src='{$plugin_url}images/adminmenus-bubbles.jpg' /></div>"), 'fields' => $bubbles, 'std' => false));
}
if (function_exists('get_fields')) {
    $options_panel->addParagraph(sprintf('<hr /><h4 class="h3-mtt">%s</h4>', __('ADVANCED CUSTOM FIELDS', 'mtt')));
    $users_arr = B5F_MTT_Utils::get_users_array();
    // ACF CPT PAGE
    if ($users_arr) {
        $ACF_hide_from_users[] = $options_panel->addSelect('for_user', $users_arr, array('name' => __('Select authorized user.', 'mtt'), 'desc' => '', 'std' => array('none')), true);
        $options_panel->addCondition('plugins_acf_show_only', array('name' => __('Advanced Custom Fields: show ACF menu only for one user.', 'mtt'), 'desc' => '', 'fields' => $ACF_hide_from_users, 'std' => false));
    }
    // ACF OPTIONS ADDON PAGE
    if (class_exists('acf_options_page_plugin')) {
        if ($users_arr) {
            $ACF_hide_options_from_users[] = $options_panel->addSelect('for_user', $users_arr, array('name' => __('If you want to show only for one user, select bellow.', 'mtt'), 'desc' => __('If none is selected, the Options are only hidden from non-administrators.', 'mtt'), 'std' => array('none')), true);
            $options_panel->addCondition('plugins_acf_hide_options', array('name' => __('Advanced Custom Fields: hide "Options" from non-administrators', 'mtt'), 'desc' => '', 'fields' => $ACF_hide_options_from_users, 'std' => false));
        }
    }
}
$options_panel->addParagraph(sprintf('<hr /><h4 class="h3-mtt">%s</h4><p>%s</p>', __('RENAME POSTS', 'mtt'), __('to whatever you want (i.e. news, articles)', 'mtt')));
$Post_rename_fields[] = $options_panel->addText('name', array('name' => __('Name', 'mtt'), 'std' => ''), true);
$Post_rename_fields[] = $options_panel->addText('singular_name', array('name' => __('Singular Name', 'mtt'), 'std' => ''), true);
$Post_rename_fields[] = $options_panel->addText('add_new', array('name' => __('Add New', 'mtt'), 'std' => ''), true);
$Post_rename_fields[] = $options_panel->addText('edit_item', array('name' => __('Edit Posts', 'mtt'), 'std' => ''), true);
$Post_rename_fields[] = $options_panel->addText('view_item', array('name' => __('View Posts', 'mtt'), 'std' => ''), true);
$Post_rename_fields[] = $options_panel->addText('search_items', array('name' => __('Search Posts', 'mtt'), 'std' => ''), true);
$Post_rename_fields[] = $options_panel->addText('not_found', array('name' => __('No Posts found', 'mtt'), 'std' => ''), true);
$Post_rename_fields[] = $options_panel->addText('not_found_in_trash', array('name' => __('No Posts found in trash', 'mtt'), 'std' => ''), true);
$options_panel->addCondition('posts_rename_enable', array('name' => __('Enable renaming the word "Posts"', 'mtt'), 'desc' => sprintf(__('Maybe you prefer it to be called News or Articles and don\'t want to create a Custom Post Type for that.<br />Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/9224/12615')), 'fields' => $Post_rename_fields, 'std' => false, 'validate_func' => 'validate_post_renaming'));
$options_panel->CloseTab();
Beispiel #6
0
<?php

/**
 * MULTISITE options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('multisite');
$options_panel->Title(__('Multisite', 'mtt'));
$options_panel->addParagraph(sprintf('%s<br /><strong>%s</strong>', __('This section only appears in the main site and for super-admins.', 'mtt'), __('All settings applied in the Plugins section are also applied in the network screen.', 'mtt')));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('SITE COLUMNS', 'mtt')));
$options_panel->addCheckbox('multisite_site_id_column', array('name' => __('Site ID', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('multisite_blogname_column', array('name' => __('Site Name', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('multisite_themes_column', array('name' => __('Show theme used by site.', 'mtt'), 'desc' => __('Also shows parent/child.', 'mtt'), 'std' => false));
$options_panel->addCheckbox('multisite_blog_size_column', array('name' => __('Show the space used by each site.', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('UTILS', 'mtt')));
$quick_edit[] = $options_panel->addCheckboxList('remove', array('backend' => __('Dashboard', 'mtt'), 'visit' => __('Visit', 'mtt'), 'edit' => __('Edit', 'mtt'), 'spam' => __('Spam', 'mtt'), 'delete' => __('Delete', 'mtt'), 'activate' => __('Activate', 'mtt'), 'deactivate' => __('Deactivate', 'mtt'), 'archive' => __('Archive', 'mtt'), 'unarchive' => __('Unarchive', 'mtt')), array('name' => __('Also remove these actions:', 'mtt'), 'desc' => __('This feature also blocks attempts to access the URL directly', 'mtt'), 'class' => 'no-toggle', 'std' => false), true);
$options_panel->addCondition('multisite_extra_quick_edit', array('name' => __('Add Users/Themes/Settings to each site quick links', 'mtt'), 'desc' => __('Fast access to the site details edit tabs.', 'mtt'), 'fields' => $quick_edit, 'std' => false));
$options_panel->addCheckbox('multisite_user_role_column', array('name' => __('Modify Users column to display the role of each user in each site.', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('multisite_redirect_new_site', array('name' => __('Redirect to site details after new site creation.', 'mtt'), 'desc' => __('The default behavior is to stay in the same screen', 'mtt'), 'std' => false));
$options_panel->addCheckbox('multisite_sort_sites_names', array('name' => __('Sort sites by name and domain.', 'mtt'), 'desc' => sprintf(__('Sorted by name in the Admin Bar, and by domain in Sites of User. This is a hook into get_blogs_of_user, and I\'m not sure if it has adverse effects elsewhere. Feedback is welcome, use the WPSE post. Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/77812/12615')), 'std' => false));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('DASHBOARD WIDGETS', 'mtt')));
$options_panel->addCheckbox('multisite_active_plugins_widget', array('name' => __('Enable Active Plugins widget', 'mtt'), 'desc' => __('Lists all network activated plugins, and all sites with their plugins.', 'mtt'), 'std' => false));
$options_panel->addCheckboxList('multisite_dashboard_remove', array('right_now' => __('Right now', 'mtt'), 'plugins' => __('Plugins', 'mtt'), 'primary' => __('WordPress Blog', 'mtt'), 'secondary' => __('Other WordPress News', 'mtt')), array('name' => __('Remove dashboard widgets', 'mtt'), 'desc' => sprintf(__('WordPress Blog and Other WP News titles and feed addresses can be configured. Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('Helen on WordPress', 'http://helen.wordpress.com/2011/08/01/customizing-the-special-multisite-dashboards/')), 'class' => 'no-toggle', 'std' => false));
$options_panel->CloseTab();
Beispiel #7
0
<?php

/**
 * PLUGINS options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('plugins');
$options_panel->Title(__('Plugins', 'mtt'));
$options_panel->addCheckbox('plugins_block_update_notice', array('name' => __('Block plugins upgrade check', 'mtt'), 'desc' => __('Not recommended, use by your own.', 'mtt'), 'std' => false));
$options_panel->addCheckbox('plugins_block_update_inactive_plugins', array('name' => __('Block inactive plugins upgrade check', 'mtt'), 'desc' => __("You'd probably be better deleting them alltogether. Doesn't work in Multisite.", 'mtt'), 'std' => false));
$options_panel->addCheckbox('plugins_remove_plugin_edit', array('name' => __('Remove plugins quick edit links (activate/deactivate, edit, settings)', 'mtt'), 'desc' => __('You will have to work only with batch actions, but you can achieve the smallest plugin listing,', 'mtt'), 'std' => false));
$options_panel->addCheckbox('plugins_remove_description', array('name' => __('Remove descriptions but leave Version and Author information.', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('plugins_remove_plugin_notice', array('name' => __('Remove extra plugins notices (normally in yellow)', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('plugins_add_last_updated', array('name' => __('Adds information about last update of the plugins', 'mtt'), 'desc' => sprintf(__('Incorporation of the plugin: %s. After enabling this, the first load of the plugins page may take a while for the information be retrieved. After the first load, the information is cached for 24 hours.', 'mtt'), B5F_MTT_Utils::make_tip_credit('Plugin Last Updated', 'http://wordpress.org/extend/plugins/plugin-last-updated/')), 'std' => false));
$options_panel->addColor('plugins_inactive_bg_color', array('name' => __('Inactive Plugins background color', 'mtt'), 'desc' => ''));
$My_plugins_color[] = $options_panel->addText('names', array('name' => __("Enter a list of keywords separated by comma, no spaces. Normally, you'll use the plugin authors.", 'mtt'), 'std' => ''), true);
$My_plugins_color[] = $options_panel->addColor('color', array('name' => __('Your Plugins background color ;o)', 'mtt'), 'desc' => ''), true);
$My_plugins_color[] = $options_panel->addCheckbox('display_count', array('name' => __('Display count', 'mtt'), 'desc' => '', 'std' => false), true);
$options_panel->addCondition('plugins_my_plugins_bg_color', array('name' => __('Colorize specific plugins.', 'mtt'), 'desc' => __('Use to display some plugins (yours!) with other color.', 'mtt'), 'fields' => $My_plugins_color, 'std' => false, 'validate_func' => 'validate_colorize_plugins'));
$options_panel->CloseTab();
Beispiel #8
0
<?php

/**
 * Admin Bar options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('admin_bar');
$options_panel->Title(__('Admin Bar', 'mtt'));
$options_panel->addParagraph(sprintf('<p class="menu-refresh-notice">%s<br />%s</p>', __("The options to hide/show/modify menu items", 'mtt'), __("need a second refresh of the plugin's page.", 'mtt')));
$options_panel->addCheckbox('adminbar_completely_disable', array('name' => __('Completely remove the Admin Bar', 'mtt'), 'desc' => sprintf(__('Remove from back and front end. Creates a "Visit Site" link in the Dashboard menu item. Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/77648/12615')), 'std' => false));
$options_panel->addCheckbox('adminbar_disable', array('name' => __('Disable Admin Bar for all users in Frontend', 'mtt'), 'desc' => '', 'std' => false));
$yoast = array();
if (defined('WPSEO_URL')) {
    $yoast = array('seo_by_yoast' => __('SEO by Yoast', 'mtt'));
}
$adminbar_remove_defaults = array('wp_logo' => __('WP logo', 'mtt'), 'site_name' => __('Site name', 'mtt'), 'updates' => __('Updates', 'mtt'), 'comments' => __('Comments', 'mtt'), 'new_content' => __('New content', 'mtt'), 'theme_options' => __('Theme options', 'mtt'), 'my_account' => __('My account', 'mtt'));
$adminbar_remove_array = array_merge($adminbar_remove_defaults, $yoast);
$options_panel->addCheckboxList('adminbar_remove', $adminbar_remove_array, array('name' => __('Remove default items', 'mtt'), 'desc' => '', 'class' => 'no-toggle', 'std' => false));
$Howdy_change[] = $options_panel->addText('howdy', array('name' => __('Replace with', 'mtt'), 'desc' => __('Leave empty for complete removal', 'mtt'), 'std' => ''), true);
$options_panel->addCondition('adminbar_howdy_enable', array('name' => __('Remove or change "Howdy"', 'mtt'), 'desc' => '', 'fields' => $Howdy_change, 'std' => false, 'validate_func' => 'validate_adminbar'));
$Adminbar_sitename_fields[] = $options_panel->addText('title', array('name' => __('Title', 'mtt'), 'desc' => '', 'std' => ''), true);
$Adminbar_sitename_fields[] = $options_panel->addImage('icon', array('name' => __('Icon (between 16x16 and 22x22 pixels)', 'mtt'), 'std' => '', 'desc' => '', 'preview_height' => 'auto', 'preview_width' => '140px'), true);
$Adminbar_sitename_fields[] = $options_panel->addText('url', array('name' => __('URL', 'mtt'), 'desc' => '', 'std' => ''), true);
$options_panel->addCondition('adminbar_sitename_enable', array('name' => __('Add Site Name with Icon', 'mtt'), 'desc' => __('Add a custom link with title and icon', 'mtt'), 'fields' => $Adminbar_sitename_fields, 'validate_func' => 'validate_adminbar', 'std' => false));
$Adminbar_custom_menu_fields[] = $options_panel->addText('bar_0_title', array('name' => __('Menu name', 'mtt'), 'desc' => __('*Required', 'mtt'), 'std' => ''), true);
$Adminbar_custom_menu_fields[] = $options_panel->addText('bar_0_url', array('name' => __('Menu link', 'mtt'), 'desc' => __('If empty, makes a null link', 'mtt'), 'std' => ''), true);
$options_panel->addCondition('adminbar_custom_enable', array('name' => __('Enable Custom Menu', 'mtt'), 'desc' => '', 'fields' => $Adminbar_custom_menu_fields, 'validate_func' => 'validate_adminbar', 'std' => false));
$repeater_menus[] = $options_panel->addText('title', array('name' => __('Title', 'mtt')), true);
$repeater_menus[] = $options_panel->addText('url', array('name' => __('URL ', 'mtt')), true);
Beispiel #9
0
<?php

/**
 * DASHBOARD options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('dashboard');
$options_panel->Title(__('Dashboard', 'mtt'));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('REMOVE DASHBOARD WIDGETS', 'mtt')));
$options_panel->addCheckboxList('dashboard_remove', array('quick_press' => __('QuickPress', 'mtt'), 'incoming_links' => __('Incoming Links', 'mtt'), 'right_now' => __('Right now', 'mtt'), 'plugins' => __('Plugins', 'mtt'), 'recent_drafts' => __('Recent Drafts', 'mtt'), 'recent_comments' => __('Recent Comments', 'mtt'), 'primary' => __('WordPress Blog', 'mtt'), 'secondary' => __('Other WordPress News', 'mtt'), 'welcome' => __('Welcome Panel', 'mtt')), array('name' => __('Remove default items', 'mtt'), 'desc' => __('<code>WordPress Blog</code> and <code>Other WP News</code> titles and feed addresses can be configured in the widget itself.', 'mtt'), 'class' => 'no-toggle', 'std' => false));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('CUSTOMIZE RIGHT NOW WIDGET', 'mtt')));
$options_panel->addCheckbox('dashboard_add_cpt_enable', array('name' => __('Add Custom Post Types to Right Now Widget', 'mtt'), 'desc' => sprintf(__('Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/1567/12615')), 'std' => false));
$options_panel->addCheckbox('dashboard_remove_footer_rightnow', array('name' => __('Hide the footer of Right Now widget', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('ADD CUSTOM WIDGETS', 'mtt')));
$repeater_fields[] = $options_panel->addText('title', array('name' => __('Title', 'mtt')), true);
$repeater_fields[] = $options_panel->addTextarea('content', array('name' => __('Content ', 'mtt')), true);
$repeater_fields[] = $options_panel->addRoles('roles', array('type' => 'checkbox_list'), array('name' => __('Show to roles', 'apc'), 'class' => 'no-fancy', 'desc' => __('Leave empty to show to all.', 'mtt')), true);
$repeater_fields[] = $options_panel->addCheckbox('enabled', array('name' => __('Enable this widget', 'mtt')), true);
$options_panel->addRepeaterBlock('dashboard_add_widgets', array('sortable' => true, 'inline' => false, 'name' => __('Custom widgets', 'mtt'), 'fields' => $repeater_fields, 'desc' => __('Add as many as you want.', 'mtt')));
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('EXTRA WIDGETS', 'mtt')));
$options_panel->addCheckboxList('dashboard_folder_size', array('root' => __('Root', 'mtt'), 'wpcontent' => __('WP Content', 'mtt')), array('name' => __('Calculate Folders Size', 'mtt'), 'desc' => __('The root calculation is usefull when WP is installed at the root of the server.', 'mtt'), 'class' => 'no-toggle', 'std' => false));
$options_panel->CloseTab();
Beispiel #10
0
<?php

/**
 * USERS and PROFILE options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('user_profile');
$options_panel->Title(__('User profile', 'mtt'));
$options_panel->addCheckbox('profile_h3_titles', array('name' => __('Remove All Titles', 'mtt'), 'desc' => __('Removes the titles: "Personal Options", "Name", "Contact Info" and "About Yourself"', 'mtt'), 'std' => false));
$options_panel->addCheckbox('profile_descriptions', array('name' => __('Remove All Descriptions', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('profile_slim', array('name' => __('Remove Visual Editor, Admin Color Scheme and Keyboard Shortcuts', 'mtt'), 'desc' => __('My guess is that or you want them all, or you don\'t want them at all :)', 'mtt'), 'std' => false));
$options_panel->addCheckbox('profile_hidden', array('name' => __('Completely hide the Personal Options block', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('profile_display_name', array('name' => __('Remove Display Name', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('profile_nickname', array('name' => __('Remove Nickname', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('profile_website', array('name' => __('Remove Website', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCheckbox('profile_social', array('name' => __('Change <strong>Aim</strong>-<strong>Yim</strong>-<strong>Jabber</strong> for <strong>Twitter</strong>-<strong>Facebook</strong>-<strong>LinkedIn</strong>', 'mtt'), 'desc' => __('You have to choose between this one or the next one.', 'mtt'), 'std' => false));
$options_panel->addCheckbox('profile_none', array('name' => __('Remove Aim/Yim/Jabber', 'mtt'), 'desc' => __('You have to choose between this one or the previous one.', 'mtt'), 'std' => false));
$options_panel->addCheckbox('profile_bio', array('name' => __('Hide the About Yourself title and Biographical Info box', 'mtt'), 'desc' => '', 'std' => false));
$options_panel->addCode('profile_css', array('name' => __('Custom CSS', 'mtt'), 'desc' => sprintf(__('Add your custom css to further stylize the Profile page.<br />Test <code>#wpwrap{}</code> with %s', 'mtt'), B5F_MTT_Utils::make_tip_credit(__('some gradients', 'mtt'), 'http://www.colorzilla.com/gradient-editor/')), 'std' => '.class-name {}', 'theme' => 'dark', 'syntax' => 'css'));
$options_panel->CloseTab();
Beispiel #11
0
$options_panel->addCheckbox('wpdisable_nourl', array('name' => __('Hide blog URL from WordPress "phone home"', 'mtt'), 'desc' => sprintf(__('Filter out the blog URL from the data that is sent to wordpress.org - Check this %s to learn more.', 'mtt'), B5F_MTT_Utils::make_tip_credit(__('article', 'mtt'), 'http://lynnepope.net/wordpress-privacy')), 'std' => false));
$options_panel->addCheckbox('wpdisable_selfping', array('name' => __('Disable Self Ping', 'mtt'), 'desc' => __('Prevents WordPress from sending pings/trackbacks to your own site.', 'mtt'), 'std' => false));
$options_panel->addCheckbox('wpdisable_redirect_disallow', array('name' => __('Redirect unauthorized attempts.', 'mtt'), 'desc' => sprintf(__('If the user tries to access an admin page directly via URL, e.g.: /wp-admin/plugins.php, instead of showing "you do not have persmissions", the browser is redirected to the frontend. Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/57206/12615')), 'std' => false));
/***********************************
 *          TAXONOMY COLUMNS
 ***********************************/
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('TAXONOMIES', 'mtt')));
$options_panel->addCheckbox('wptaxonomy_columns', array('name' => __('Enable ID column', 'mtt'), 'desc' => sprintf(__('Show column ID in taxonomies screens. Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/q/77532/12615')), 'std' => false));
/***********************************
 *          RSS
 ***********************************/
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('RSS', 'mtt')));
$Enable_rss_delay[] = $options_panel->addText('time', array('name' => __('Number of delay', 'mtt'), 'desc' => '', 'std' => ''), true);
$Enable_rss_delay[] = $options_panel->addSelect('period', array('MINUTE' => __('MINUTE', 'mtt'), 'HOUR' => __('HOUR', 'mtt'), 'DAY' => __('DAY', 'mtt'), 'WEEK' => __('WEEK', 'mtt'), 'MONTH' => __('MONTH', 'mtt'), 'YEAR' => __('YEAR', 'mtt')), array('name' => __('Period of delay', 'mtt'), 'desc' => '', 'class' => 'no-fancy', 'std' => array('MINUTE')), true);
$options_panel->addCondition('wprss_delay_publish_enable', array('name' => __('Delay RSS feed update', 'mtt'), 'desc' => sprintf(__('This can give you time to make corrections after publishing a post, delaying the update in your RSS feed. Or you can make your content web exclusive for a larger period. Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/1896/12615')), 'fields' => $Enable_rss_delay, 'std' => false, 'validate_func' => 'validate_general_tab'));
/***********************************
 *          ASSORTED
 ***********************************/
//$options_panel->addParagraph( sprintf( '<hr /><h4>%s</h4>', __( 'ASSORTED', 'mtt' ) ) );
/***********************************
 *          AUTOCOWERKS
 ***********************************/
$options_panel->addParagraph(sprintf('<hr /><h4>%s</h4>', __('AUTOCOWERKS', 'mtt')));
$options_panel->addCheckbox('wpdisable_smartquotes', array('name' => __('Disable SmartQuotes', 'mtt'), 'desc' => __('Prevent the conversion of straight quotes into directional quotes.', 'mtt'), 'std' => false));
$options_panel->addCheckbox('wpdisable_capitalp', array('name' => __('Disable Capital P', 'mtt'), 'desc' => __('Prevents WordPress of auto-correcting mispellings of its name. Check this <a href="http://justintadlock.com/archives/2010/07/08/lowercase-p-dangit">article</a>', 'mtt'), 'std' => false));
$options_panel->addCheckbox('wpdisable_autop', array('name' => __('Disable Auto P', 'mtt'), 'desc' => __('Prevents WordPress from inserting automatic &lt;p&gt; tags in your code.', 'mtt'), 'std' => false));
$options_panel->addCheckbox('wpdisable_wptitle', array('name' => __('Remove WordPress from admin page titles', 'mtt'), 'desc' => sprintf(__('The browser title has "- WordPress" appended to it. This will remove it. Tip via: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('WordPress Answers', 'http://wordpress.stackexchange.com/a/17034/12615')), 'std' => false));
/**
 * END
 */
$options_panel->CloseTab();
Beispiel #12
0
<?php

/**
 * SHORTCODES options
 *
 * @package    ManyTipsTogether
 * @subpackage B5F_MTT_Admin
 */
$options_panel->OpenTab('shortcodes');
$options_panel->Title(__('Shortcodes', 'mtt'));
$options_panel->addCheckbox('shortcodes_everywhere', array('name' => __('Enable shortcodes everywhere', 'mtt'), 'desc' => sprintf(__('In the text widget, excerpts, content and category/tag/taxonomy descriptions. Code by: %s', 'mtt'), B5F_MTT_Utils::make_tip_credit('Thomas Scholz', 'https://github.com/toscho/WordPress-Shortcodes/')), 'std' => false));
$tubedesc = '<div class="desc">' . __('Usage:', 'mtt') . ' <code>[poptube id="VIDEO-ID" title="TITLE-OVER-THUMBNAIL" color="#CCCF27" button="WATCH NOW"]</code>
            <div style="text-align:center;width:170px;margin:0 0 15px">
            <h2 style="color:#CCCF27;text-shadow:none;padding:0;margin-bottom:0;">' . __('TITLE-OVER', 'mtt') . '</h2>
            <a href="http://www.youtube.com/watch_popup?v=s-c_urzTWYQ" target="_blank">
            <img src="http://i3.ytimg.com/vi/s-c_urzTWYQ/default.jpg" alt="youtube thumbnail" style="margin-bottom:-19px"/>
            </a><br />
            <a class="button-secondary" href="http://www.youtube.com/watch_popup?v=s-c_urzTWYQ" target="_blank">' . __('WATCH NOW', 'mtt') . '</a></div>' . __('The "color" attribute is for the title.<br />
            This is the default backend style, for adpating it in your theme 
            use the class "mtt-poptube" for the elements', 'mtt') . ' <em>&lt;h2&gt;</em>, <em>&lt;img&gt;</em> ' . __('and', 'mtt') . ' <em>&lt;a&gt;</em></div>';
$options_panel->addCheckbox('shortcodes_tube', array('name' => __('Enable YouTube shortcode', 'mtt'), 'desc' => $tubedesc, 'std' => false));
$options_panel->addCheckbox('shortcodes_gdocs', array('name' => __('Enable Google Docs Preview Document shortcode', 'mtt'), 'desc' => __('Use Google Docs for preview PDF, Word, Excel docuemtns online. <a href="http://docs.google.com/viewer?url=partners.adobe.com/public/developer/en/xml/AdobeXMLFormsSamples.pdf" target="_blank">Example</a>.<br />Usage: <code>[gdocs url="http://www.domain.com/document.pdf" class="my-doc-class"]View Document[/gdocs]</code>', 'mtt'), 'std' => false));
$options_panel->CloseTab();