Changeset 7054 for trunk/bp-core/bp-core-functions.php
- Timestamp:
- 05/11/2013 11:42:45 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core/bp-core-functions.php
r7024 r7054 1080 1080 1081 1081 return $new_args; 1082 } 1083 1084 /** 1085 * Sanitize an 'order' parameter for use in building SQL queries 1086 * 1087 * Strings like 'DESC', 'desc', ' desc' will be interpreted into 'DESC'. 1088 * Everything else becomes 'ASC'. 1089 * 1090 * @since BuddyPress (1.8) 1091 * @param string $order The 'order' string, as passed to the SQL constructor 1092 * @return string The sanitized value 'DESC' or 'ASC' 1093 */ 1094 function bp_esc_sql_order( $order = '' ) { 1095 $order = strtoupper( trim( $order ) ); 1096 return 'DESC' === $order ? 'DESC' : 'ASC'; 1082 1097 } 1083 1098
Note: See TracChangeset
for help on using the changeset viewer.