/** * Setup the sort tool and return it for topics display * * @return titania_sort */ public static function build_sort() { // Setup the sort and set the sort keys $sort = new titania_sort(); $sort->set_sort_keys(self::$sort_by); if (isset(self::$sort_by[phpbb::$user->data['user_topic_sortby_type']])) { $sort->default_sort_key = phpbb::$user->data['user_topic_sortby_type']; } $sort->default_sort_dir = phpbb::$user->data['user_topic_sortby_dir']; $sort->default_limit = phpbb::$config['topics_per_page']; $sort->result_lang = 'TOTAL_TOPICS'; return $sort; }
/** * Setup the sort tool and return it for contributions display * * @return titania_sort */ public static function build_sort() { // Setup the sort and set the sort keys $sort = new titania_sort(); $sort->set_sort_keys(self::$sort_by); // Show update time descending and limit to the topics per page by default $sort->set_defaults(phpbb::$config['topics_per_page'], 't', 'd'); $sort->result_lang = 'TOTAL_CONTRIBS'; return $sort; }
/** * Setup the sort tool and return it for posts display * * @return titania_sort */ public static function build_sort() { // Setup the sort and set the sort keys $sort = new titania_sort(); $sort->set_sort_keys(self::$sort_by); $sort->set_defaults(phpbb::$config['topics_per_page']); return $sort; }