Correction --- if( $r['data'][$currRecId]['fieldname'][0] == $vlValue ) { $tmpVLValue[] = '<option value="'.$vlValue.'" selected>'.$vlValue; } else { $tmpVLValue[] = '<option value="'.$vlValue.'">'.$vlValue; }