Search Results for 'code'
-
Search Results
-
Topic: No Filters or Actions ??
Hello folks,
I was hoping that someone could point me in the direction of an ACTION that occurs on the following pages so that I can hook my plugin into them without hacking the core:
bb-edit.php
I have a plugin that needs to be fired when someone edits a post.
Forum layout update
In the backend we do it all through AJAX (how wonderful), except we call the following page bb-admin/admin-ajax.php and the following sections (via a switch statement): add-forums and order-forums.
Except, no actions there to call either. And yes, to the best of my ability, I’ve stuck with the code the whole way through all the functions they call. I’ve yet to find a pluggable one.
===============================================================================
I realise that my phrasing is sometimes considered combative, and I apologise for that, but are we seriously suggesting that at no point is the ability to add/edit/control/order our forum pluggable in anyway; and the same for the editing of a forum post??
I’m more than happy to be wrong here, because right now I’m having one of those “bbPress moments” where you’re not quite sure if you’re losing your marbles or if whoever decided to make these not pluggable is.
Thanks for the help
Topic: Show only Parent Forums
I want to show only the very top level forums on my front page. I have tried:
<?php if ( bb_forums("depth=1") ) : ?>But that didn’t work and all the forums still show up. I only want to show the very top level, so for example if I have the following forums:
Main
- Sub Forum 1
- Sub Forum 2
--- Sub Forum 2.1
--- Sub Forum 2.1
- Sub Forum 3
Community
- Sub Forum 1
- Sub Forum 2
--- Sub Forum 2.1
--- Sub Forum 2.1
- Sub Forum 3Only Main and Community would appear on the home page.
Thanks.
I have a large number of topics within a forum that are generated externally with all of them having the same topic start, topic and post date (initial post)
The forum also contains other topics (user added) and of course additional posts which have later times.
The normal display shows the freshest post at the top Which is exactly what is wanted however the rest of the list (the as yet unanswered topics) are listed in an order that seems to be driven by the topic_id. This is not what is required for my site.
I want to change the order of these “unanswered topics” to an alphabetical sequence based on the topic_title.
Examining the table bb_topics and drilling the code from forum.php downwards it appeared that the USE INDEX() given to BB_Query was ‘forum_time’ This index is combined on topic_time and topic_id which explains the normal listing.
I changed this index to a combined topic_time and topic_title(20)
The result was unexpected. The replied topics are still listed first (descending time) however, the unanswered topics are now listed in descending/reverse alphabetical order!
Evidently the DESC sql is being added to the entire query – both time and title.
I have been unable to find out where or find an alternative.
Any suggestions welcome – and I’m quite happy moding the code though would prefer to make this minimal as it could make upgrades problematic.
Thanks in advance
