Change ordering of posts/topics
Quote from Asgaros on February 26, 2019, 5:54 pmHello @tomtom
Why you not just change the ordering in Forum -> Structure? For each category you can add a numerical value in the “Order” input-field which is used to order your categories as you need.
Hello @tomtom
Why you not just change the ordering in Forum -> Structure? For each category you can add a numerical value in the “Order” input-field which is used to order your categories as you need.
Quote from tomtom on February 26, 2019, 6:09 pmI’ve now done this and to somewhat got it kinda fixed. However the drug of choice should be last and welcome to the tenah house should be 2nd… cannot seem to get this to happen with this method. I’m obviously doing this wrong. Any suggestions? Thanks so much. I also run this for on my site and have no issues, i even got a banner up on top, but i cannot seem to do that either. Admitting i am very rusty. I do apologize
I’ve now done this and to somewhat got it kinda fixed. However the drug of choice should be last and welcome to the tenah house should be 2nd… cannot seem to get this to happen with this method. I’m obviously doing this wrong. Any suggestions? Thanks so much. I also run this for on my site and have no issues, i even got a banner up on top, but i cannot seem to do that either. Admitting i am very rusty. I do apologize
Uploaded files:Quote from tomtom on February 26, 2019, 6:14 pmOk, i found my error. Thank you, where should i post about the Banner at the top being added? You are a great help. My order for the 2nd cat was set at 60. All fixed.
Ok, i found my error. Thank you, where should i post about the Banner at the top being added? You are a great help. My order for the 2nd cat was set at 60. All fixed.
Quote from Changes on June 20, 2019, 12:31 pmQuote from Asgaros on January 24, 2017, 12:51 pmThe available filters allow you to change the odering of your posts and topics. Here are a few code-example which you have to add to your themes functions.php file if you want to use them.
Show newest posts first in topic
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');
- function custom_asgarosforum_filter_get_posts_order($order) {
- $order = ‘p1.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_posts_order’, ‘custom_asgarosforum_filter_get_posts_order’);
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');Show newest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Show oldest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Sort topics in forums by name
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.name ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
Quote from Asgaros on January 24, 2017, 12:51 pmThe available filters allow you to change the odering of your posts and topics. Here are a few code-example which you have to add to your themes functions.php file if you want to use them.
Show newest posts first in topic
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');
- function custom_asgarosforum_filter_get_posts_order($order) {
- $order = ‘p1.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_posts_order’, ‘custom_asgarosforum_filter_get_posts_order’);
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');Show newest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Show oldest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Sort topics in forums by name
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.name ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
Quote from Asgaros on January 24, 2017, 12:51 pmThe available filters allow you to change the odering of your posts and topics. Here are a few code-example which you have to add to your themes functions.php file if you want to use them.
Show newest posts first in topic
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');
- function custom_asgarosforum_filter_get_posts_order($order) {
- $order = ‘p1.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_posts_order’, ‘custom_asgarosforum_filter_get_posts_order’);
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');Show newest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Show oldest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Sort topics in forums by name
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.name ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
Quote from Asgaros on January 24, 2017, 12:51 pmThe available filters allow you to change the odering of your posts and topics. Here are a few code-example which you have to add to your themes functions.php file if you want to use them.
Show newest posts first in topic
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');
- function custom_asgarosforum_filter_get_posts_order($order) {
- $order = ‘p1.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_posts_order’, ‘custom_asgarosforum_filter_get_posts_order’);
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');Show newest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Show oldest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Sort topics in forums by name
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.name ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
Hello Thomas, your advise is from 2017.
I want to be sure I can do this without causing any troubles.
Can I add this at the bottom of functions.php?
Rob
Quote from Asgaros on January 24, 2017, 12:51 pmThe available filters allow you to change the odering of your posts and topics. Here are a few code-example which you have to add to your themes functions.php file if you want to use them.
Show newest posts first in topic
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');
- function custom_asgarosforum_filter_get_posts_order($order) {
- $order = ‘p1.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_posts_order’, ‘custom_asgarosforum_filter_get_posts_order’);
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');Show newest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Show oldest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Sort topics in forums by name
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.name ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
Quote from Asgaros on January 24, 2017, 12:51 pmThe available filters allow you to change the odering of your posts and topics. Here are a few code-example which you have to add to your themes functions.php file if you want to use them.
Show newest posts first in topic
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');
- function custom_asgarosforum_filter_get_posts_order($order) {
- $order = ‘p1.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_posts_order’, ‘custom_asgarosforum_filter_get_posts_order’);
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');Show newest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Show oldest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Sort topics in forums by name
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.name ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
Quote from Asgaros on January 24, 2017, 12:51 pmThe available filters allow you to change the odering of your posts and topics. Here are a few code-example which you have to add to your themes functions.php file if you want to use them.
Show newest posts first in topic
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');
- function custom_asgarosforum_filter_get_posts_order($order) {
- $order = ‘p1.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_posts_order’, ‘custom_asgarosforum_filter_get_posts_order’);
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');Show newest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Show oldest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Sort topics in forums by name
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.name ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
Quote from Asgaros on January 24, 2017, 12:51 pmThe available filters allow you to change the odering of your posts and topics. Here are a few code-example which you have to add to your themes functions.php file if you want to use them.
Show newest posts first in topic
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');
- function custom_asgarosforum_filter_get_posts_order($order) {
- $order = ‘p1.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_posts_order’, ‘custom_asgarosforum_filter_get_posts_order’);
function custom_asgarosforum_filter_get_posts_order($order) { $order = 'p1.id DESC'; return $order; } add_filter('asgarosforum_filter_get_posts_order', 'custom_asgarosforum_filter_get_posts_order');Show newest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id DESC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id DESC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Show oldest topics first in forum
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.id ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.id ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');Sort topics in forums by name
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
- function custom_asgarosforum_filter_get_threads_order($order) {
- $order = ‘t.name ASC’;
- return $order;
- }
- add_filter(‘asgarosforum_filter_get_threads_order’, ‘custom_asgarosforum_filter_get_threads_order’);
function custom_asgarosforum_filter_get_threads_order($order) { $order = 't.name ASC'; return $order; } add_filter('asgarosforum_filter_get_threads_order', 'custom_asgarosforum_filter_get_threads_order');
Hello Thomas, your advise is from 2017.
I want to be sure I can do this without causing any troubles.
Can I add this at the bottom of functions.php?
Rob
Quote from Asgaros on June 20, 2019, 1:36 pmHello @changes
The code is still working fine – I just tested it. 🙂
Hello @changes
The code is still working fine – I just tested it. 🙂
Quote from makane on August 1, 2020, 12:31 amHi, I’m wondering if there might be a way for users to change the ordering on the fly, perhaps by date/most popular/upvotes-downvotes. Thanks!
Hi, I’m wondering if there might be a way for users to change the ordering on the fly, perhaps by date/most popular/upvotes-downvotes. Thanks!
Quote from Asgaros on August 11, 2020, 7:46 amHello @makane
A sorting-functionality for this is not implemented it. But I will take your suggestion into consideration for future upates.
Hello @makane
A sorting-functionality for this is not implemented it. But I will take your suggestion into consideration for future upates.
Quote from Jim on January 29, 2022, 10:23 pmIs it possible to restrict these sorting filters to one forum (or topic)? I guess the necessary ids are not available when filtering?
Is it possible to restrict these sorting filters to one forum (or topic)? I guess the necessary ids are not available when filtering?
Quote from Jim on February 5, 2022, 9:24 pm@asgaros
Is it somehow possible to force the filter
asgarosforum_filter_get_posts_order
to act on just one topic or forum?
Is it somehow possible to force the filter asgarosforum_filter_get_posts_order
to act on just one topic or forum?