$FileCache =& get_FileCache();
     $attachments = explode(',', $comment_attachments);
     $final_attachments = explode(',', $checked_attachments);
     // create attachments checklist
     $list_options = array();
     foreach ($attachments as $attachment_ID) {
         $attachment_File = $FileCache->get_by_ID($attachment_ID, false);
         if ($attachment_File) {
             // checkbox should be checked only if the corresponding file id is in the final attachments array
             $checked = in_array($attachment_ID, $final_attachments);
             $list_options[] = array('preview_attachment' . $attachment_ID, 1, '', $checked, false, $attachment_File->get('name'));
         }
     }
     if (!empty($list_options)) {
         // display list
         $Form->checklist($list_options, 'comment_attachments', T_('Attached files'));
     }
     // memorize all attachments ids
     $Form->hidden('preview_attachments', $comment_attachments);
 }
 if ($Item->can_attach()) {
     // Display attach file input field
     $Form->input_field(array('label' => T_('Attach files'), 'note' => '<br />' . get_upload_restriction(), 'name' => 'uploadfile[]', 'type' => 'file', 'size' => '30'));
 }
 $comment_options = array();
 if (!is_logged_in(false)) {
     // User is not logged in:
     $comment_options[] = '<label><input type="checkbox" class="checkbox" name="comment_cookies" tabindex="7"' . ($comment_cookies ? ' checked="checked"' : '') . ' value="1" /> ' . T_('Remember me') . '</label>' . ' <span class="note">(' . T_('For my next comment on this site') . ')</span>';
     // TODO: If we got info from cookies, Add a link called "Forget me now!" (without posting a comment).
     $msgform_class_start = '';
     $msgform_class_end = '';
Example #2
0
$Form->hidden('action', 'update');
// --------------------------------------------
if ($current_User->check_perm('users', 'edit')) {
    $Form->begin_fieldset(T_('Locking down b2evolution for maintenance, upgrade or server switching...'));
    $Form->checkbox_input('system_lock', $Settings->get('system_lock'), T_('Lock system'), array('note' => T_('check this to prevent login (except for admins) and sending comments/messages. This prevents the DB from receiving updates (other than logging)') . '<br />' . T_('Note: for a more complete lock down, rename the file /conf/_maintenance.html to /conf/maintenance.html (complete lock) or /conf/imaintenance.html (gives access to /install)')));
    $Form->end_fieldset();
}
// --------------------------------------------
$Form->begin_fieldset(T_('Caching'));
$Form->checkbox_input('general_cache_enabled', $Settings->get('general_cache_enabled'), T_('Enable general cache'), array('note' => T_('Cache rendered pages that are not controlled by a skin. See Blog Settings for skin output caching.')));
$Form->end_fieldset();
// --------------------------------------------
$Form->begin_fieldset(T_('Online Help') . get_manual_link('online help'));
$Form->checkbox_input('webhelp_enabled', $Settings->get('webhelp_enabled'), T_('Online Help links'), array('note' => T_('Online help links provide context sensitive help to certain features.')));
$Form->end_fieldset();
// --------------------------------------------
$Form->begin_fieldset(T_('Hit & session logging') . get_manual_link('hit_logging'));
$Form->checklist(array(array('log_public_hits', 1, T_('on every public page'), $Settings->get('log_public_hits')), array('log_admin_hits', 1, T_('on every admin page'), $Settings->get('log_admin_hits'))), 'log_hits', T_('Log hits'));
// TODO: draw a warning sign if set to off
$Form->radio_input('auto_prune_stats_mode', $Settings->get('auto_prune_stats_mode'), array(array('value' => 'off', 'label' => T_('Off'), 'note' => T_('Not recommended! Your database will grow very large!'), 'onclick' => 'jQuery("#auto_prune_stats_container").hide();'), array('value' => 'page', 'label' => T_('On every page'), 'note' => T_('This is guaranteed to work but uses extra resources with every page displayed.'), 'onclick' => 'jQuery("#auto_prune_stats_container").show();'), array('value' => 'cron', 'label' => T_('With a scheduled job'), 'note' => T_('Recommended if you have your scheduled jobs properly set up.'), 'onclick' => 'jQuery("#auto_prune_stats_container").show();')), T_('Auto pruning'), array('note' => T_('Note: Even if you don\'t log hits, you still need to prune sessions!'), 'lines' => true));
echo '<div id="auto_prune_stats_container">';
$Form->text_input('auto_prune_stats', $Settings->get('auto_prune_stats'), 5, T_('Prune after'), T_('days. How many days of hits & sessions do you want to keep in the database for stats?'));
echo '</div>';
if ($Settings->get('auto_prune_stats_mode') == 'off') {
    // hide the "days" input field, if mode set to off:
    echo '<script type="text/javascript">jQuery("#auto_prune_stats_container").hide();</script>';
}
$Form->end_fieldset();
if ($current_User->check_perm('options', 'edit')) {
    $Form->end_form(array(array('submit', 'submit', T_('Save !'), 'SaveButton'), array('reset', '', T_('Reset'), 'ResetButton')));
}
// put this on feedback details container, this way it won't be displayed if comment posting is not allowed
echo '<div class="feedback_details_container">';
$Form->select_input_array('new_feedback_status', $edited_Blog->get_setting('new_feedback_status'), $status_options, T_('New feedback status'), $newstatus_warning . T_('Logged in users will get the highest possible status allowed by their permissions. Plugins may also override this default.'));
echo '</div>';
// Moderation statuses setting
$not_moderation_statuses = array_diff(get_visibility_statuses('keys', NULL), get_visibility_statuses('moderation'));
// Get moderation statuses with status text
$moderation_statuses = get_visibility_statuses('', $not_moderation_statuses);
$blog_moderation_statuses = $edited_Blog->get_setting('moderation_statuses');
$checklist_options = array();
foreach ($moderation_statuses as $status => $status_text) {
    // Add a checklist option for each possible modeartion status
    $is_checked = strpos($blog_moderation_statuses, $status) !== false;
    $checklist_options[] = array('notif_' . $status, 1, $status_text, $is_checked);
}
$Form->checklist($checklist_options, 'moderation_statuses', T_('Comment moderation reminder statuses'), false, false, array('note' => 'Comments with the selected statuses will be notified on the "Send reminders about comments awaiting moderation" scheduled job.'));
$Form->radio('comment_quick_moderation', $edited_Blog->get_setting('comment_quick_moderation'), array(array('never', T_('Never')), array('expire', T_('Links expire on first edit action')), array('always', T_('Always available'))), T_('Comment quick moderation'), true);
$Form->end_fieldset();
$Form->begin_fieldset(T_('RSS/Atom feeds'));
$Form->radio('comment_feed_content', $edited_Blog->get_setting('comment_feed_content'), array(array('none', T_('No feeds')), array('excerpt', T_('Comment excerpts')), array('normal', T_('Standard comment contents'))), T_('Comment feed contents'), true, T_('How much content do you want to make available in comment feeds?'));
$Form->text('comments_per_feed', $edited_Blog->get_setting('comments_per_feed'), 4, T_('Comments in feeds'), T_('How many of the latest comments do you want to include in RSS & Atom feeds?'), 4);
$Form->end_fieldset();
$Form->begin_fieldset(T_('Subscriptions'));
$Form->checkbox('allow_item_subscriptions', $edited_Blog->get_setting('allow_item_subscriptions'), T_('Email subscriptions'), T_('Allow users to subscribe and receive email notifications for comments on a specific post.'));
$Form->end_fieldset();
$Form->begin_fieldset(T_('Registration of commenters'));
$Form->checkbox('comments_detect_email', $edited_Blog->get_setting('comments_detect_email'), T_('Email addresses'), T_('Detect email addresses in comments.'));
$Form->checkbox('comments_register', $edited_Blog->get_setting('comments_register'), T_('Register after comment'), T_('Display the registration form right after submitting a comment.'));
$Form->end_fieldset();
$Form->end_form(array(array('submit', 'submit', T_('Save !'), 'SaveButton'), array('reset', '', T_('Reset'), 'ResetButton')));
?>
$Form->info('', sprintf(T_('Feedbacks with a spam karma between these two thresholds will get the default status of the blog ("%s").'), T_('New feedback status')));
$Form->end_fieldset();
$Form->begin_fieldset(T_('Misc') . get_manual_link('antispam-settings-misc'));
$Form->checkbox('antispam_block_spam_referers', $Settings->get('antispam_block_spam_referers'), T_('Block spam referers'), T_('If a referrer has been detected as spam, should we block the request with a "403 Forbidden" page?'));
$Form->checkbox('antispam_report_to_central', $Settings->get('antispam_report_to_central'), T_('Report to central blacklist'), T_('When banning a keyword, offer an option to report to the central blacklist.') . ' [<a href="http://b2evolution.net/about/terms.html">' . T_('Terms of service') . '</a>]');
$Form->end_fieldset();
$Form->begin_fieldset(T_('Spam detection relevance weight') . get_manual_link('antispam-settings-detection-relevance-weight'));
echo '<p>' . T_('This defines the weight of the plugin, in relation to the others.') . '</p>';
$karma_plugins = $Plugins->get_list_by_events(array('GetSpamKarmaForComment'));
if (empty($karma_plugins)) {
    echo '<p>' . T_('There are no spam karma plugins enabled.') . '</p>';
} else {
    foreach ($karma_plugins as $loop_Plugin) {
        $Form->text('antispam_plugin_spam_weight[' . $loop_Plugin->ID . ']', $Plugins->index_ID_rows[$loop_Plugin->ID]['plug_spam_weight'], 2, $loop_Plugin->name);
    }
}
$Form->end_fieldset();
$Form->begin_fieldset(T_('Suspect users') . get_manual_link('antispam-settings-suspect-users'));
$GroupCache =& get_GroupCache(true, NT_('Don\'t move suspect users'));
$Form->select_object('antispam_suspicious_group', $Settings->get('antispam_suspicious_group'), $GroupCache, T_('Move suspect users to'), '', true);
$trust_groups = $Settings->get('antispam_trust_groups') != '' ? explode(',', $Settings->get('antispam_trust_groups')) : array();
$groups_options = array();
$groups = $GroupCache->get_option_array();
foreach ($groups as $group_ID => $group_name) {
    $groups_options[] = array('antispam_trust_groups[]', $group_ID, $group_name, in_array($group_ID, $trust_groups));
}
$Form->checklist($groups_options, 'antispam_trust_groups', T_('Never touch users from these groups'));
$Form->end_fieldset();
if ($current_User->check_perm('options', 'edit')) {
    $Form->end_form(array(array('submit', 'submit', T_('Save Changes!'), 'SaveButton'), array('submit', 'submit[restore_defaults]', T_('Restore defaults'), 'ResetButton')));
}
Example #5
0
		}
	}
</script>

<?php 
$blogurl = $edited_Blog->gen_blogurl();
$Form = new Form(NULL, 'coll_features_checkchanges');
$Form->begin_form('fform');
$Form->add_crumb('collection');
$Form->hidden_ctrl();
$Form->hidden('action', 'update');
$Form->hidden('tab', 'seo');
$Form->hidden('blog', $edited_Blog->ID);
$Form->begin_fieldset(T_('Main page / post list') . get_manual_link('main_page_seo'));
$Form->checkbox('default_noindex', $edited_Blog->get_setting('default_noindex'), T_('Default blog page'), T_('META NOINDEX'));
$Form->checklist(array(array('canonical_homepage', 1, T_('301 redirect to canonical URL when possible'), $edited_Blog->get_setting('canonical_homepage')), array('relcanonical_homepage', 1, T_('Use rel="canonical" if not 301 redirected'), $edited_Blog->get_setting('relcanonical_homepage'))), 'canonical_homepage_options', T_('Make canonical'));
$Form->checkbox('paged_noindex', $edited_Blog->get_setting('paged_noindex'), T_('"Next" blog pages'), T_('META NOINDEX') . ' - ' . T_('Page 2,3,4...'));
$Form->checkbox('paged_nofollowto', $edited_Blog->get_setting('paged_nofollowto'), '', T_('NOFOLLOW on links to') . ' ' . T_('Page 2,3,4...'));
$Form->radio('title_link_type', $edited_Blog->get_setting('title_link_type'), array(array('permalink', T_('Link to the permanent url of the post')), array('linkto_url', T_('Link to the "link to URL" specified in the post (if any)')), array('auto', T_('Link to the "link to URL" if specified, otherwise fall back to permanent url')), array('none', T_('No links on titles'))), T_('Post titles'), true);
// TODO: checkbox display "permalink" separately from the title
$Form->radio('main_content', $edited_Blog->get_setting('main_content'), array(array('excerpt', T_('Post excerpts')), array('normal', T_('Standard post contents (stopping at "&lt;!-- more -->")')), array('full', T_('Full post contents (including after "&lt;!-- more -->")'))), T_('Post contents'), true);
$Form->radio('permalinks', $edited_Blog->get_setting('permalinks'), array(array('single', T_('Link to single post')), array('archive', T_('Link to post in archive')), array('subchap', T_('Link to post in sub-category'))), T_('Permalinks'), true);
$Form->end_fieldset();
$Form->begin_fieldset(T_('Single post pages / "Permalink" pages') . get_manual_link('single_post_pages_seo'));
$Form->radio('single_links', $edited_Blog->get_setting('single_links'), array(array('param_num', T_('Use param: post ID'), T_('E-g: ') . url_add_param($blogurl, '<strong>p=123&amp;more=1</strong>')), array('param_title', T_('Use param: post title'), T_('E-g: ') . url_add_param($blogurl, '<strong>title=post-title&amp;more=1</strong>')), array('short', T_('Use extra-path: post title'), T_('E-g: ') . url_add_tail($blogurl, '<strong>/post-title</strong>')), array('y', T_('Use extra-path: year'), T_('E-g: ') . url_add_tail($blogurl, '<strong>/2006/post-title</strong>')), array('ym', T_('Use extra-path: year & month'), T_('E-g: ') . url_add_tail($blogurl, '<strong>/2006/12/post-title</strong>')), array('ymd', T_('Use extra-path: year, month & day'), T_('E-g: ') . url_add_tail($blogurl, '<strong>/2006/12/31/post-title</strong>')), array('subchap', T_('Use extra-path: sub-category'), T_('E-g: ') . url_add_tail($blogurl, '<strong>/subcat/post-title</strong>')), array('chapters', T_('Use extra-path: category path'), T_('E-g: ') . url_add_tail($blogurl, '<strong>/cat/subcat/post-title</strong>'))), T_('Permalink scheme'), true);
$Form->text_input('slug_limit', $edited_Blog->get_setting('slug_limit'), 3, T_('Limit slug length to'), '', array('input_suffix' => ' ' . T_('words')));
$Form->checklist(array(array('canonical_item_urls', 1, T_('301 redirect to canonical URL when possible'), $edited_Blog->get_setting('canonical_item_urls')), array('relcanonical_item_urls', 1, T_('Use rel="canonical" if not 301 redirected'), $edited_Blog->get_setting('relcanonical_item_urls'))), 'canonical_item_urls_options', T_('Make canonical'));
$Form->checkbox('excerpts_meta_description', $edited_Blog->get_setting('excerpts_meta_description'), T_('Meta description'), T_('When no meta description is proviced for an item, use the excerpt instead.'));
$Form->checkbox('tags_meta_keywords', $edited_Blog->get_setting('tags_meta_keywords'), T_('Meta Keywords'), T_('When no meta keywords are provided for an item, use tags instead.'));
$Form->end_fieldset();
$Form->begin_fieldset(T_('"By date" archives') . get_manual_link('archive_pages_seo'));
$Form = new Form(NULL, 'settings_checkchanges');
$Form->begin_form('fform', '', array('onsubmit' => 'var es=this.elements; for( var i=0; i < es.length; i++ ) { es[i].disabled=false; };'));
$Form->add_crumb('collectionsettings');
$Form->hidden('ctrl', 'collections');
$Form->hidden('tab', 'blog_settings');
$Form->hidden('action', 'update_settings_blog');
// --------------------------------------------
$Form->begin_fieldset(T_('Display options') . get_manual_link('collections-display-options'));
$Form->select_input_options('blogs_order_by', array_to_option_list(get_coll_sort_options(), $Settings->get('blogs_order_by')), T_('Order blogs by'), T_('Select blog list order.'));
$Form->select_input_options('blogs_order_dir', array_to_option_list(array('ASC' => T_('Ascending'), 'DESC' => T_('Descending')), $Settings->get('blogs_order_dir')), T_('Order direction'), T_('Select default blog list order direction.'));
$Form->end_fieldset();
// --------------------------------------------
$Form->begin_fieldset(T_('Caching') . get_manual_link('collections-caching-settings'));
$Form->checkbox_input('general_cache_enabled', $Settings->get('general_cache_enabled'), get_icon('page_cache_on') . ' ' . T_('Enable general cache'), array('note' => T_('Cache rendered pages that are not controlled by a skin. See Blog Settings for skin output caching.')));
$cache_note = '(' . T_('See Blog Settings for existing') . ')';
$Form->checklist(array(array('newblog_cache_enabled', 1, T_('Enable page cache for NEW blogs'), $Settings->get('newblog_cache_enabled'), false, $cache_note), array('newblog_cache_enabled_widget', 1, T_('Enable widget cache for NEW blogs'), $Settings->get('newblog_cache_enabled_widget'), false, $cache_note)), 'new_blogs_cahe', T_('Enable for new blogs'));
$Form->end_fieldset();
// --------------------------------------------
$Form->begin_fieldset(T_('After each new post or comment...') . get_manual_link('after_each_post_settings'));
$Form->radio_input('outbound_notifications_mode', $Settings->get('outbound_notifications_mode'), array(array('value' => 'off', 'label' => T_('Off'), 'note' => T_('No notification about your new content will be sent out.')), array('value' => 'immediate', 'label' => T_('Immediate'), 'note' => T_('This is guaranteed to work but may create an annoying delay after each post or comment publication.')), array('value' => 'cron', 'label' => T_('Asynchronous'), 'note' => T_('Recommended if you have your scheduled jobs properly set up.'))), T_('Outbound pings & email notifications'), array('lines' => true));
$Form->end_fieldset();
// --------------------------------------------
$Form->begin_fieldset(T_('Categories') . get_manual_link('categories_global_settings'), array('id' => 'categories'));
$Form->checkbox_input('allow_moving_chapters', $Settings->get('allow_moving_chapters'), T_('Allow moving categories'), array('note' => T_('Check to allow moving categories accross blogs. (Caution: can break pre-existing permalinks!)')));
$Form->end_fieldset();
// --------------------------------------------
$Form->begin_fieldset(T_('Cross posting') . get_manual_link('collections-cross-posting-settings'));
$Form->checklist(array(array('cross_posting', 1, T_('Allow cross-posting posts to several blogs'), $Settings->get('cross_posting'), false, T_('(Extra cats in different blogs)')), array('cross_posting_blogs', 1, T_('Allow moving posts between different blogs'), $Settings->get('cross_posting_blogs'), false, T_('(Main cat can move to different blog)'))), 'allow_cross_posting', T_('Cross Posting'));
$Form->checkbox_input('redirect_moved_posts', $Settings->get('redirect_moved_posts'), T_('Redirect if post has moved'), array('note' => T_('check to allow redirects to the correct blog when a post was found in a different blog.')));
$Form->end_fieldset();
// --------------------------------------------
 * @var the action destination of the form (NULL for pagenow)
 */
global $form_action;
$Form = new Form($form_action, 'user_checkchanges');
$form_class = 'fform user_contact_form';
$Form->title_fmt = '<span style="float:right">$global_icons$</span><div>$title$</div>' . "\n";
$Form->begin_form($form_class);
$Form->hidden('blog', $Blog->ID);
$Form->add_crumb('user');
$Form->hidden('user_ID', $edited_User->ID);
$close_icon = '';
if ($display_mode == 'js') {
    // Display a close link for popup window
    $close_icon = action_icon(T_('Close this window'), 'close', '', '', 0, 0, array('id' => 'close_button', 'class' => 'floatright'));
}
$Form->begin_fieldset(T_('Contact Groups') . $close_icon, array('class' => 'fieldset clear'));
// Contact groups:
$current_user_groups = get_contacts_groups_array();
$active_groups = get_contacts_groups_by_user_ID($edited_User->ID);
$is_contact = check_contact($edited_User->ID);
$group_options = array();
foreach ($current_user_groups as $group_ID => $group_title) {
    $group_options[] = array('contact_groups[]', $group_ID, $group_title, in_array($group_ID, $active_groups));
}
$group_options[] = array('contact_groups[]', 'new', T_('new') . ': <input type="text" name="contact_group_new" class="form-control" />', false, false, '', 'contact_group_new');
$Form->checklist($group_options, 'contact_groups', '', false, false, array('wide' => true));
// Block the contact:
$blocked_options = array(array('contact_blocked', 1, T_('Block this contact from contacting you.'), $is_contact === false));
$Form->checklist($blocked_options, 'contact_blocked', '', false, false, array('wide' => true));
$Form->end_fieldset();
$Form->end_form(array(array('value' => T_('Save'), 'name' => 'actionArray[contact_group_save]')));
$Form->hidden_ctrl();
$Form->hidden('action', 'update');
$Form->hidden('tab', 'comments');
$Form->hidden('blog', $edited_Blog->ID);
$Form->begin_fieldset(T_('Comment viewing options') . get_manual_link('comment-viewing-options'));
$Form->radio('allow_view_comments', $edited_Blog->get_setting('allow_view_comments'), array(array('any', T_('Any user'), T_('Including anonymous users')), array('registered', T_('Registered users only')), array('member', T_('Members only'), T_('Users have to be members of this blog')), array('moderator', T_('Moderators & Admins only'))), T_('Comment viewing by'), true);
// put this on feedback details container, this way it won't be displayed if comment posting is not allowed
echo '<div class="feedback_details_container">';
$Form->radio('comments_orderdir', $edited_Blog->get_setting('comments_orderdir'), array(array('ASC', T_('Chronologic')), array('DESC', T_('Reverse'))), T_('Display order'), true);
$Form->checkbox('threaded_comments', $edited_Blog->get_setting('threaded_comments'), T_('Threaded comments'), T_('Check to enable hierarchical threads of comments.'));
$paged_comments_disabled = (bool) $edited_Blog->get_setting('threaded_comments');
$Form->checkbox('paged_comments', $edited_Blog->get_setting('paged_comments'), T_('Paged comments'), T_('Check to enable paged comments on the public pages.'), '', 1, $paged_comments_disabled);
$Form->text('comments_per_page', $edited_Blog->get_setting('comments_per_page'), 4, T_('Comments/Page'), T_('How many comments do you want to display on one page?'), 4);
$Form->checkbox('comments_avatars', $edited_Blog->get_setting('comments_avatars'), T_('Display profile pictures'), T_('Display profile pictures/avatars for comments.'));
$Form->checkbox('comments_latest', $edited_Blog->get_setting('comments_latest'), T_('Latest comments'), T_('Check to enable viewing of the latest comments'));
$Form->checklist(get_inskin_statuses_options($edited_Blog, 'comment'), 'comment_inskin_statuses', T_('Front office statuses'), false, false, array('note' => 'Uncheck the statuses that should never appear in the front office.'));
echo '</div>';
$Form->end_fieldset();
$Form->begin_fieldset(T_('Feedback options') . get_manual_link('comment-feedback-options'));
$advanced_perms_warning = $edited_Blog->get_advanced_perms_warning();
$Form->radio('allow_comments', $edited_Blog->get_setting('allow_comments'), array(array('any', T_('Any user'), T_('Including anonymous users'), $advanced_perms_warning, 'onclick="show_hide_feedback_details(this);"'), array('registered', T_('Registered users only'), '', '', 'onclick="show_hide_feedback_details(this);"'), array('member', T_('Members only'), T_('Users have to be members of this blog'), '', 'onclick="show_hide_feedback_details(this);"'), array('never', T_('Not allowed'), '', '', 'onclick="show_hide_feedback_details(this);"')), T_('Comment posting by'), true);
echo '<div class="feedback_details_container">';
$Form->checkbox('allow_anon_url', $edited_Blog->get_setting('allow_anon_url'), T_('Anonymous URLs'), T_('Allow anonymous commenters to submit an URL'));
$Form->checkbox('allow_html_comment', $edited_Blog->get_setting('allow_html_comment'), T_('Allow HTML'), T_('Check to allow HTML in comments.') . ' (' . T_('HTML code will pass several sanitization filters.') . ')');
$any_option = array('any', T_('Any user'), T_('Including anonymous users'), '');
$registered_option = array('registered', T_('Registered users only'), '', '');
$member_option = array('member', T_('Members only'), T_('Users have to be members of this blog'), '');
$never_option = array('never', T_('Not allowed'), '', '');
$Form->radio('allow_attachments', $edited_Blog->get_setting('allow_attachments'), array($any_option, $registered_option, $member_option, $never_option), T_('Allow attachments from'), true);
$max_attachments_params = array();
if ($edited_Blog->get_setting('allow_attachments') == 'any') {
if ($Settings->get('newusers_canregister') != 'yes') {
    // Disable group and level fields below when registration is not allowed freely
    $disabled_param_grouplevel['disabled'] = 'disabled';
}
$Form->checkbox_input('quick_registration', $Settings->get('quick_registration'), T_('Quick registration'), array_merge(array('note' => T_('Check to allow registering with email only (no username, no password) using the quick registration widget.')), $disabled_param_grouplevel));
$GroupCache =& get_GroupCache();
$Form->select_input_object('newusers_grp_ID', $Settings->get('newusers_grp_ID'), $GroupCache, T_('Group for new users'), array_merge(array('note' => T_('Groups determine user roles and permissions.')), $disabled_param_grouplevel));
$Form->text_input('newusers_level', $Settings->get('newusers_level'), 1, T_('Level for new users'), T_('Levels determine hierarchy of users in blogs.'), array_merge(array('maxlength' => 1, 'required' => true), $disabled_param_grouplevel));
$Form->end_fieldset();
// --------------------------------------------
$Form->begin_fieldset(T_('Default user settings') . get_manual_link('default-user-settings'));
$messaging_options = array(array('enable_PM', 1, T_('private messages on this site.'), $Settings->get('def_enable_PM')));
if ($Settings->get('emails_msgform') != 'never') {
    $messaging_options[] = array('enable_email', 1, T_('emails through a message form that will NOT reveal my email address.'), $Settings->get('def_enable_email'));
}
$Form->checklist($messaging_options, 'default_user_msgform', T_('Other users can send me'));
$notify_options = array(array('notify_messages', 1, T_('I receive a private message.'), $Settings->get('def_notify_messages')), array('notify_unread_messages', 1, T_('I have unread private messages for more than 24 hours.'), $Settings->get('def_notify_unread_messages'), false, T_('This notification is sent only once every 3 days.')), array('notify_published_comments', 1, T_('a comment is published on one of <strong>my</strong> posts.'), $Settings->get('def_notify_published_comments')), array('notify_comment_moderation', 1, T_('a comment is posted and I have permissions to moderate it.'), $Settings->get('def_notify_comment_moderation')), array('notify_meta_comments', 1, T_('a meta comment is posted and I have permission to view it.'), $Settings->get('def_notify_meta_comments')), array('notify_post_moderation', 1, T_('a post is created and I have permissions to moderate it.'), $Settings->get('def_notify_post_moderation')));
$Form->checklist($notify_options, 'default_user_notification', T_('Notify me by email whenever'));
$newsletter_options = array(array('newsletter_news', 1, T_('Send me news about this site.') . ' <span class="note">' . T_('Each message contains an easy 1 click unsubscribe link.') . '</span>', $Settings->get('def_newsletter_news')), array('newsletter_ads', 1, T_('I want to receive ADs that may be relevant to my interests.'), $Settings->get('def_newsletter_ads')));
$Form->checklist($newsletter_options, 'default_user_newsletter', T_('Newsletter'));
$Form->text_input('notification_email_limit', $Settings->get('def_notification_email_limit'), 3, T_('Limit notification emails to'), T_('emails per day'), array('maxlength' => 3, 'required' => true));
$Form->text_input('newsletter_limit', $Settings->get('def_newsletter_limit'), 3, T_('Limit newsletters to'), T_('emails per day'), array('maxlength' => 3, 'required' => true));
$Form->end_fieldset();
// --------------------------------------------
$Form->begin_fieldset(T_('Account activation') . get_manual_link('account-activation-settings'), array('id' => 'account_activation'));
$Form->checkbox('newusers_mustvalidate', $Settings->get('newusers_mustvalidate'), T_('New users must activate by email'), T_('Check to require users to activate their account by clicking a link sent to them via email.'));
$Form->checkbox('newusers_revalidate_emailchg', $Settings->get('newusers_revalidate_emailchg'), T_('Reactivate after email change'), T_('Check to require users to re-activate their account when they change their email address.'));
$Form->radio('validation_process', $Settings->get('validation_process'), array(array('secure', T_('Secure account activation process'), T_('Users must validate their account in the same session. Prevents activation of an account by someone else if an incorrect email address is entered. No reminder emails can be sent.')), array('easy', T_('Easy account activation process'), T_('Allows to send reminder emails to unregistered accounts.'))), T_('Activation process'), true);
$Form->duration_input('activate_requests_limit', $Settings->get('activate_requests_limit'), T_('Limit activation email requests to'), 'minutes', 'minutes', array('minutes_step' => 5, 'required' => true, 'note' => T_('Only one activation email can be sent to the same email address in every given minutes.')));
$Form->checkbox('newusers_findcomments', $Settings->get('newusers_findcomments'), T_('Find old comments'), T_('After each activation, find comments left by the user based on the validated email address and attach them to the user account.'));
if ($Settings->get('after_email_validation') == 'return_to_original') {