Skip to:
Content

Opened 5 years ago

Closed 4 years ago

#2537 closed enhancement (fixed)

User details template new hook

Reported by: dimitrov.adrian Owned by: johnjamesjacoby
Milestone: 2.6 Priority: normal
Severity: normal Version: trunk
Component: Appearance - Theme Compatibility Keywords: has-patch commit
Cc: mercijavier@…

Description

We can override the template but it will cost extra maintance if new version is updated, so one extra hook will cost so little, but can save many effort.

Attachments (5)

user-details.php.patch (388 bytes) - added by dimitrov.adrian 5 years ago.
2537.patch (522 bytes) - added by netweb 5 years ago.
2537.diff (522 bytes) - added by netweb 5 years ago.
user-details.php.2.patch (522 bytes) - added by netweb 5 years ago.
2537.2.diff (2.1 KB) - added by netweb 5 years ago.

Download all attachments as: .zip

Change History (12)

#1 @dimitrov.adrian
5 years ago

The missing patch path is

bbpress/templates/default/bbpress/user-details.php

#2 @dimitrov.adrian
5 years ago

  • Milestone changed from Awaiting Review to 2.6

@netweb
5 years ago

@netweb
5 years ago

#3 @netweb
5 years ago

Refreshed patch against /trunk

Each patch of the three patches I added are identical (2537.patch, 2537.diff​ & user-details.php.2.patch​)
Added variants for testing with grunt patch

Edit Note: The above was due to me using this ticket to test grunt patch

Providing the hook name bbp_template_after_user_details_menu_items is suitable user-details.php.2.patch is good to go.

Last edited 5 years ago by netweb (previous) (diff)

#4 @mercime
5 years ago

  • Cc mercijavier@… added

@netweb
5 years ago

#5 @netweb
5 years ago

In 2537.2.diff:

A refresh with before and and after hooks:

  • bbp_template_before_user_details_menu_items
  • bbp_template_after_user_details_menu_items

Also sneaks before and after hooks into content-single-user.php

  • bbp_template_before_user_wrapper
  • bbp_template_after_user_wrapper

#6 @netweb
5 years ago

  • Keywords commit added

#7 @johnjamesjacoby
4 years ago

  • Owner set to johnjamesjacoby
  • Resolution set to fixed
  • Status changed from new to closed

In 5854:

Templates: Add before & after hooks to user templates parts.

This changeset makes it easier to add custom text & HTML before & after user details.

Props netweb. Fixes #2537.

Note: See TracTickets for help on using tickets.