Not Sorting on the frontend
-
Hello everyone.
I have been issues with sorting my BBpress forum topic on the front end.
I arranged it in the Back-end using the drag and drop features but yet it didn’t reflect on the front-end.
So i tried to use a custom function i got from one of the threads.
Here is the code i used.
//* Change sort order of Topics within a specified bbpress forum
function my_custom_display_topic_index_query ($args) {
$thisforumid = bbp_get_forum_id();if($thisforumid == 43135) {
$args[‘orderby’] = ‘date’;
$args[‘order’] = ‘ASC’;
}return $args;
}
add_filter(‘bbp_before_has_topics_parse_args’, ‘my_custom_display_topic_index_query ‘ );and i got this error
Warning: call_user_func_array() expects parameter 1 to be a valid callback, function ‘my_custom_display_topic_index_query ‘ not found or invalid function name in /home/flexol5/public_html/wp-includes/plugin.php on line 235
Warning: array_merge(): Argument #2 is not an array in /home/flexol5/public_html/wp-content/plugins/bbpress/includes/common/functions.php on line 1419
I don’t know what i did wrong or maybe the coding structure of bbpress as changed. I would like someone to help with a way to arrange a specific forum topic in ascending order.
Thanks
https://www.ads-software.com/plugins/intuitive-custom-post-order/
- The topic ‘Not Sorting on the frontend’ is closed to new replies.