BP_Messages_Thread::convert_orderby_to_order_by_term( string $orderby )
Convert the ‘orderby’ param into a proper SQL term/column.
Description
Parameters
- $orderby
-
(Required) Orderby term as passed to get().
Return
(string) $order_by_term SQL-friendly orderby term.
Source
File: bp-messages/classes/class-bp-messages-thread.php
protected static function convert_orderby_to_order_by_term( $orderby ) { $order_by_term = ''; switch ( $orderby ) { case 'id': default: $order_by_term = 'r.id'; break; } return $order_by_term; }
Changelog
Version | Description |
---|---|
BuddyPress 1.8.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.