bp_nouveau_groups_localize_scripts (数组美元的参数=数组())
本地化Group的Invite UI所需的字符串
描述
参数
- 美元的参数
-
(数组)(可选)包含脚本所需的JS字符串的关联数组
默认值:数组()
返回
(数组)如果需要,为Group的Invite UI使用相同的数组和特定的字符串。
源
文件:bp-templates / bp-nouveau / /团体/显然也包括
函数bp_nouveau_groups_localize_scripts($params = array()) {if (!bp_is_group_invites () & & !(bp_is_group_create() && bp_is_group_creation_step('group- requests ')) {return $params;} $show_pending = bp_group_has_invitation (array('user_id' => ')) && !bp_is_group_create ();// Init Group invite nav $invites_nav = array('members' => array('id' => 'members', 'caption' => __('All members', 'buddyboss'), 'order' => array('id' => 'invited', 'caption' => __('Pending requests ', 'buddyboss'), 'order' => 90, 'hide' => (int) !show_pending美元),“邀请”= >阵列(“id”= >“邀请”的标题 ' => __( ' 发送邀请”、“buddyboss”),“秩序”= > 100年'隐藏' = > 1,href ' = > ' # send-invites-editor ',));if (bp_is_active('friends')) {$invites_nav['friends'] = array('id' => 'friends', 'caption' => __('My Connections', 'buddyboss'), 'order' => 0,);If (true === bp_nouveau_groups_disallow_all_members_invitation ()) {unset($invites_nav['members']); / /加入成员}} $params[' group_invitation '] = array('nav' => bp_sort_by_key($invites_nav, 'order', 'num'), 'loading' => __('loading成员。 Please wait.', 'buddyboss' ), 'invites_form' => __( 'Use the "Send" button to send your invite or the "Cancel" button to abort.', 'buddyboss' ), 'invites_form_reset' => __( 'Group invitations cleared. Please use one of the available tabs to select members to invite.', 'buddyboss' ), 'invites_sending' => __( 'Sending group invitations. Please wait.', 'buddyboss' ), 'removeUserInvite' => __( 'Cancel invitation %s', 'buddyboss' ), 'group_id' => ! bp_get_current_group_id() ? bp_get_new_group_id() : bp_get_current_group_id(), 'is_group_create' => bp_is_group_create(), 'nonces' => array( 'uninvite' => wp_create_nonce( 'groups_invite_uninvite_user' ), 'send_invites' => wp_create_nonce( 'groups_send_invites' ) ), ); return $params; }
更新日志
版本 | 描述 |
---|---|
BuddyPress 3.0.0 | 介绍了。 |