Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
04/08/2023 06:31:46 AM (12 months ago)
Author:
imath
Message:

Make sure all Groups component URLs are built using BP rewrites API

  • Introduce the bp_groups_get_create_url() to ease Groups create URLs generation.
  • Improve bp_groups_get_path_chunks() to deal with front-end group admin URLs and the Groups create URLs.
  • Deprecate bp_get_groups_directory_permalink() in favor of bp_get_groups_directory_url().
  • Replace all remaining deprecated functions usage.
  • Start putting deprecated functions behind a function_exists( 'bp_classic' ) check, corresponding functions were added inside the BP Classic backcompat plugin.
  • Adjust some Groups routing unit tests.

Props r-a-y, johnjamesjacoby, boonebgorges

Closes https://github.com/buddypress/buddypress/pull/83
See #4954

File:
1 edited

Legend:

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

    r13443 r13449  
    594594                'slug'      => 'create', // slug is used because BP_Core_Nav requires it, but it's the scope
    595595                'li_class'  => array( 'no-ajax', 'group-create', 'create-button' ),
    596                 'link'      => bp_get_groups_directory_url(
    597                     array(
    598                         'create_single_item' => 1,
    599                     )
    600                 ),
     596                'link'      => bp_groups_get_create_url(),
    601597                'text'      => __( 'Create a Group', 'buddypress' ),
    602598                'count'     => false,
Note: See TracChangeset for help on using the changeset viewer.