Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
04/28/2024 10:08:00 PM (2 years ago)
Author:
imath
Message:

BP Nouveau: improve PHP code standards using WPCS

See #7228 (trunk)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-templates/bp-nouveau/includes/groups/template-tags.php

    r13645 r13820  
    436436                printf(
    437437                        '<form action="%s" method="post" enctype="multipart/form-data">',
    438                         bp_get_group_creation_form_action()
     438                        esc_url( bp_get_group_creation_form_action() )
    439439                );
    440440        }
    … …  
    449449        );
    450450
    451         // The submit actions
     451        // phpcs:ignore WordPress.Security.EscapeOutput
    452452        echo $output;
    453453
    … …  
    10891089
    10901090        if ( ! bp_is_group() ) {
     1091                // phpcs:ignore WordPress.Security.EscapeOutput
    10911092                echo $group_meta->meta;
    10921093        } else {
    … …  
    11391140        }
    11401141
     1142        // phpcs:ignore WordPress.Security.EscapeOutput
    11411143        echo $meta;
    11421144}
    … …  
    13651367 *                      Defaults to the group currently being iterated on in the groups loop.
    13661368 * @param int $length   Optional. Length of returned string, including ellipsis. Default: 100.
    1367  *
    1368  * @return string Excerpt.
    13691369 */
    13701370function bp_nouveau_group_description_excerpt( $group = null, $length = null ) {
    1371         echo bp_nouveau_get_group_description_excerpt( $group, $length );
     1371        // Escaping is made in `bp-groups/bp-groups-filters.php`.
     1372        // phpcs:ignore WordPress.Security.EscapeOutput
     1373        echo apply_filters(
     1374                /** This filter is documented in bp-groups/bp-groups-template.php. */
     1375                'bp_get_group_description_excerpt',
     1376                bp_nouveau_get_group_description_excerpt( $group, $length )
     1377        );
    13721378}
    13731379
Note: See TracChangeset for help on using the changeset viewer.