function bp_new_group_enable_forum()
{
    echo bp_get_new_group_enable_forum();
}
Esempio n. 2
0
</h4>

										<?php 
        if (bp_forums_is_installed_correctly()) {
            ?>

											<p><?php 
            _e('Should this group have a forum?', 'vibe');
            ?>
</p>

											<div class="checkbox">
												<label><input type="checkbox" name="group-show-forum"
												              id="group-show-forum"
												              value="1"<?php 
            checked(bp_get_new_group_enable_forum(), true, true);
            ?>
 /> <?php 
            _e('Enable discussion forum', 'vibe');
            ?>
</label>
											</div>
										<?php 
        } elseif (is_super_admin()) {
            ?>

											<p><?php 
            printf(__('<strong>Attention Site Admin:</strong> Group forums require the <a href="%s">correct setup and configuration</a> of a bbPress installation.', 'vibe'), bp_core_do_network_admin() ? network_admin_url('settings.php?page=bb-forums-setup') : admin_url('admin.php?page=bb-forums-setup'));
            ?>
</p>
Esempio n. 3
0
        /**
         * Show forums and new forum form when creating a group
         *
         * @since bbPress (r3465)
         */
        public function create_screen($group_id = 0)
        {
            // Bail if not looking at this screen
            if (!bp_is_group_creation_step($this->slug)) {
                return false;
            }
            // Check for possibly empty group_id
            if (empty($group_id)) {
                $group_id = bp_get_new_group_id();
            }
            $checked = bp_get_new_group_enable_forum() || groups_get_groupmeta($group_id, 'forum_id');
            ?>

		<h4><?php 
            esc_html_e('Group Forum', 'bbpress');
            ?>
</h4>

		<p><?php 
            esc_html_e('Create a discussion forum to allow members of this group to communicate in a structured, bulletin-board style fashion.', 'bbpress');
            ?>
</p>

		<div class="checkbox">
			<label><input type="checkbox" name="bbp-create-group-forum" id="bbp-create-group-forum" value="1"<?php 
            checked($checked);
            ?>
 /> <?php 
            esc_html_e('Yes. I want this group to have a forum.', 'bbpress');
            ?>
</label>
		</div>

		<?php 
        }
Esempio n. 4
0
        ?>
</label>
					</div>
					<?php 
    }
    ?>

					<?php 
    if (function_exists('bp_forums_is_installed_correctly')) {
        ?>
						<?php 
        if (bp_forums_is_installed_correctly()) {
            ?>
							<div class="checkbox">
								<label><input type="checkbox" name="group-show-forum" id="group-show-forum" value="1"<?php 
            if (bp_get_new_group_enable_forum()) {
                ?>
 checked="checked"<?php 
            }
            ?>
 /> <?php 
            _e('Enable discussion forum', 'buddypress');
            ?>
</label>
							</div>
						<?php 
        } else {
            ?>
							<?php 
            if (is_site_admin()) {
                ?>
Esempio n. 5
0
        /**
         * Show forums and new forum form when creating a group
         *
         * @since bbPress (r3465)
         */
        public function create_screen()
        {
            // Bail if not looking at this screen
            if (!bp_is_group_creation_step($this->slug)) {
                return false;
            }
            $checked = bp_get_new_group_enable_forum() || groups_get_groupmeta(bp_get_new_group_id(), 'forum_id');
            ?>

		<h4><?php 
            _e('Group Forums', 'bbpress');
            ?>
</h4>

		<p><?php 
            _e('Create a discussion forum to allow members of this group to communicate in a structured, bulletin-board style fashion.', 'bbpress');
            ?>
</p>

		<div class="checkbox">
			<label><input type="checkbox" name="bbp-create-group-forum" id="bbp-create-group-forum" value="1"<?php 
            checked($checked);
            ?>
 /> <?php 
            _e('Yes. I want this group to have a forum.', 'bbpress');
            ?>
</label>
		</div>

		<?php 
            // Verify intent
            wp_nonce_field('groups_create_save_' . $this->slug);
        }