Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
04/23/2015 05:08:50 AM (7 years ago)
Author:
tw2113
Message:

Adds hooks documentation for the groups template files.

See #5948.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-templates/bp-legacy/buddypress/groups/single/admin.php

    r9757 r9786  
    77<form action="<?php bp_group_admin_form_action(); ?>" name="group-settings-form" id="group-settings-form" class="standard-form" method="post" enctype="multipart/form-data" role="main">
    88
    9 <?php do_action( 'bp_before_group_admin_content' ); ?>
     9<?php
     10
     11/**
     12 * Fires inside the group admin form and before the content.
     13 *
     14 * @since BuddyPress (1.1.0)
     15 */
     16do_action( 'bp_before_group_admin_content' ); ?>
    1017
    1118<?php /* Edit Group Details */ ?>
    1219<?php if ( bp_is_group_admin_screen( 'edit-details' ) ) : ?>
    1320
    14     <?php do_action( 'bp_before_group_details_admin' ); ?>
     21    <?php
     22
     23    /**
     24     * Fires before the display of group admin details.
     25     *
     26     * @since BuddyPress (1.1.0)
     27     */
     28    do_action( 'bp_before_group_details_admin' ); ?>
    1529
    1630    <label for="group-name"><?php _e( 'Group Name (required)', 'buddypress' ); ?></label>
     
    2034    <textarea name="group-desc" id="group-desc" aria-required="true"><?php bp_group_description_editable(); ?></textarea>
    2135
    22     <?php do_action( 'groups_custom_group_fields_editable' ); ?>
     36    <?php
     37
     38    /**
     39     * Fires after the group description admin details.
     40     *
     41     * @since BuddyPress (1.0.0)
     42     */
     43    do_action( 'groups_custom_group_fields_editable' ); ?>
    2344
    2445    <p>
     
    2849    </p>
    2950
    30     <?php do_action( 'bp_after_group_details_admin' ); ?>
     51    <?php
     52
     53    /**
     54     * Fires after the display of group admin details.
     55     *
     56     * @since BuddyPress (1.1.0)
     57     */
     58    do_action( 'bp_after_group_details_admin' ); ?>
    3159
    3260    <p><input type="submit" value="<?php esc_attr_e( 'Save Changes', 'buddypress' ); ?>" id="save" name="save" /></p>
     
    3866<?php if ( bp_is_group_admin_screen( 'group-settings' ) ) : ?>
    3967
    40     <?php do_action( 'bp_before_group_settings_admin' ); ?>
     68    <?php
     69
     70    /**
     71     * Fires before the group settings admin display.
     72     *
     73     * @since BuddyPress (1.1.0)
     74     */
     75    do_action( 'bp_before_group_settings_admin' ); ?>
    4176
    4277    <?php if ( bp_is_active( 'forums' ) ) : ?>
     
    113148    <hr />
    114149
    115     <?php do_action( 'bp_after_group_settings_admin' ); ?>
     150    <?php
     151
     152    /**
     153     * Fires after the group settings admin display.
     154     *
     155     * @since BuddyPress (1.1.0)
     156     */
     157    do_action( 'bp_after_group_settings_admin' ); ?>
    116158
    117159    <p><input type="submit" value="<?php esc_attr_e( 'Save Changes', 'buddypress' ); ?>" id="save" name="save" /></p>
     
    180222<?php if ( bp_is_group_admin_screen( 'manage-members' ) ) : ?>
    181223
    182     <?php do_action( 'bp_before_group_manage_members_admin' ); ?>
     224    <?php
     225
     226    /**
     227     * Fires before the group manage members admin display.
     228     *
     229     * @since BuddyPress (1.1.0)
     230     */
     231    do_action( 'bp_before_group_manage_members_admin' ); ?>
    183232
    184233    <div class="bp-widget">
     
    284333                                <a href="<?php bp_group_member_remove_link(); ?>" class="button confirm" title="<?php esc_attr_e( 'Remove this member', 'buddypress' ); ?>"><?php _e( 'Remove from group', 'buddypress' ); ?></a>
    285334
    286                                 <?php do_action( 'bp_group_manage_members_admin_item' ); ?>
     335                                <?php
     336
     337                                /**
     338                                 * Fires inside the display of a member admin item in group management area.
     339                                 *
     340                                 * @since BuddyPress (1.1.0)
     341                                 */
     342                                do_action( 'bp_group_manage_members_admin_item' ); ?>
    287343
    288344                            </span>
     
    303359    </div>
    304360
    305     <?php do_action( 'bp_after_group_manage_members_admin' ); ?>
     361    <?php
     362
     363    /**
     364     * Fires after the group manage members admin display.
     365     *
     366     * @since BuddyPress (1.1.0)
     367     */
     368    do_action( 'bp_after_group_manage_members_admin' ); ?>
    306369
    307370<?php endif; ?>
     
    310373<?php if ( bp_is_group_admin_screen( 'membership-requests' ) ) : ?>
    311374
    312     <?php do_action( 'bp_before_group_membership_requests_admin' ); ?>
     375    <?php
     376
     377    /**
     378     * Fires before the display of group membership requests admin.
     379     *
     380     * @since BuddyPress (1.1.0)
     381     */
     382    do_action( 'bp_before_group_membership_requests_admin' ); ?>
    313383
    314384        <div class="requests">
     
    318388        </div>
    319389
    320     <?php do_action( 'bp_after_group_membership_requests_admin' ); ?>
    321 
    322 <?php endif; ?>
    323 
    324 <?php do_action( 'groups_custom_edit_steps' ) // Allow plugins to add custom group edit screens ?>
     390    <?php
     391
     392    /**
     393     * Fires after the display of group membership requests admin.
     394     *
     395     * @since BuddyPress (1.1.0)
     396     */
     397    do_action( 'bp_after_group_membership_requests_admin' ); ?>
     398
     399<?php endif; ?>
     400
     401<?php
     402
     403/**
     404 * Fires inside the group admin template.
     405 *
     406 * Allows plugins to add custom group edit screens.
     407 *
     408 * @since BuddyPress (1.1.0)
     409 */
     410do_action( 'groups_custom_edit_steps' ); ?>
    325411
    326412<?php /* Delete Group Option */ ?>
    327413<?php if ( bp_is_group_admin_screen( 'delete-group' ) ) : ?>
    328414
    329     <?php do_action( 'bp_before_group_delete_admin' ); ?>
     415    <?php
     416
     417    /**
     418     * Fires before the display of group delete admin.
     419     *
     420     * @since BuddyPress (1.1.0)
     421     */
     422    do_action( 'bp_before_group_delete_admin' ); ?>
    330423
    331424    <div id="message" class="info">
     
    335428    <label><input type="checkbox" name="delete-group-understand" id="delete-group-understand" value="1" onclick="if(this.checked) { document.getElementById('delete-group-button').disabled = ''; } else { document.getElementById('delete-group-button').disabled = 'disabled'; }" /> <?php _e( 'I understand the consequences of deleting this group.', 'buddypress' ); ?></label>
    336429
    337     <?php do_action( 'bp_after_group_delete_admin' ); ?>
     430    <?php
     431
     432    /**
     433     * Fires after the display of group delete admin.
     434     *
     435     * @since BuddyPress (1.1.0)
     436     */
     437    do_action( 'bp_after_group_delete_admin' ); ?>
    338438
    339439    <div class="submit">
     
    348448    <input type="hidden" name="group-id" id="group-id" value="<?php bp_group_id(); ?>" />
    349449
    350 <?php do_action( 'bp_after_group_admin_content' ); ?>
     450<?php
     451
     452/**
     453 * Fires inside the group admin form and after the content.
     454 *
     455 * @since BuddyPress (1.1.0)
     456 */
     457do_action( 'bp_after_group_admin_content' ); ?>
    351458
    352459</form><!-- #group-settings-form -->
Note: See TracChangeset for help on using the changeset viewer.