Filter Hook: The field we want to order by is either in $_GET[‘orderby’] when the user has chosen to reorder posts or saved in the plugin settings ‘default-sort-key.’ The sort direction is in $_GET[‘order’] or ‘default-sort-order.’


Filter Hook: Determine if this meta field should be sorted as a number 1. Parse out the meta key name from $pieces[‘where’] 2. Run it through $vehicle->post_meta_value_is_number