bp_group_show_albums_status_setting( string $setting, object|bool $group = false )

Output the ‘checked’ value, if needed, for a given album_status on the group create/admin screens

Description

Parameters

$setting

(string) (Required) The setting you want to check against ('members', 'mods', or 'admins').

$group

(object|bool) (Optional) Group object. Default: current group in loop.

Default value: false

Source

File: bp-groups/bp-groups-template.php

function bp_group_show_albums_status_setting( $setting, $group = false ) {
	$group_id = isset( $group->id ) ? $group->id : false;

	$album_status = bp_group_get_album_status( $group_id );

	if ( $setting == $album_status ) {
		echo ' checked="checked"';
	}
}

Changelog

Changelog
Version Description
BuddyBoss 1.0.0 Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.