Skip to:
Content

BuddyPress.org

Opened 14 years ago

Closed 14 years ago

#2129 closed defect (bug) (fixed)

add action hook to forum topic theme li

Reported by: dwenaus's profile dwenaus Owned by: dwenaus's profile dwenaus
Milestone: 1.2.4 Priority: normal
Severity: Version:
Component: Forums Keywords: has-patch
Cc:

Description

for the rate forum posts plugin i've created it would be helpful to alter forum topic classes, for this i'm requesting a new action hook in the file /bp-default/groups/single/forum/topic.php

on line 29 change this:

<li id="post-<?php bp_the_topic_post_id() ?>">

to something like

<li id="post-<?php bp_the_topic_post_id() ?>" <?php do_action( 'groups_forum_topic_post_class' ) ?> >

or maybe topic_post_li

right now i'm doing it with ajax, which necessitates another useless server call, as pointed out by andrew_1. (thanks :)

Attachments (2)

2129.diff (731 bytes) - added by dwenaus 14 years ago.
2129_forum_topic.diff (1.8 KB) - added by dwenaus 14 years ago.

Download all attachments as: .zip

Change History (16)

#1 @dwenaus
14 years ago

  • Keywords has-patch added
  • Owner set to dwenaus
  • Status changed from new to accepted

this diff works and is tested.

@dwenaus
14 years ago

#2 @dwenaus
14 years ago

tested and it works

#3 @dwenaus
14 years ago

  • Status changed from accepted to assigned

#4 @dwenaus
14 years ago

  • Component set to Forums
  • Milestone changed from 1.3 to 1.2.4
  • Priority changed from minor to normal

please implement this in 1.2.4

#5 @dwenaus
14 years ago

while you are at this one, it would make a lot of sense to add action hooks at the top and bottom of this file. They are sorely missing.

#6 @dwenaus
14 years ago

I've attached a new diff file that incorporates other very needed hooks for this file.
PLEASE include in 1.2.4

#7 @dwenaus
14 years ago

  • Type changed from enhancement to defect

#8 follow-up: @dwenaus
14 years ago

ignore 2129.diff

#9 in reply to: ↑ 8 @dwenaus
14 years ago

Replying to dwenaus:

ignore 2129.diff

use 2129_forum_topic.diff instead

#10 @johnjamesjacoby
14 years ago

  • Milestone changed from 1.2.4 to 1.3

Going to move this to 1.3.

Both topics.php and edit.php will need to be normalized, and that's a little too much to put into a point release.

#11 @dwenaus
14 years ago

PLEASE PLEASE PLEASE do not move this to 1.3. I've been waiting sooooo long for these simple hooks to be added into core.

Soon the email subscription/digest plugin will be very popular when we release it in about a week, and having the hook on line 19 will mean that people don't have to go in and manually add it every upgrade.

likewise the hook on line 33 will mean the rate forum posts plugin can change the look of posts without a useless extra jquery call on every page load.

is there any way you could at least add just the changes on line 19 and 33? and normalize the page later?

and active buddypress developer is begging you, PLEASE :)

#12 @dwenaus
14 years ago

if adding line 33 is too much, can you at least add line 19?

#13 @dwenaus
14 years ago

  • Milestone changed from 1.3 to 1.2.4

I'm just going to switch this back to 1.2.4 so that someone sees my plea :) I hope that's OK.

#14 @johnjamesjacoby
14 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [2972]) Fixes #2129.

Note: See TracTickets for help on using tickets.