public function replyToSortCustomColumn($aVars) { if (isset($aVars['orderby']) && 'samplecolumn' == $aVars['orderby']) { $aVars = array_merge($aVars, array('meta_key' => 'metabox_text_field', 'orderby' => 'meta_value')); } return $aVars; }