<?php echo veronika_location_format(osc_item_country(), osc_item_region(), osc_item_city()); ?>
function veronika_location_format($country = null, $region = null, $city = null) { if($country <> '') { if(strlen($country) == 2) { $country_full = Country::newInstance()->findByCode($country); } else { $country_full = Country::newInstance()->findByName($country); } if($region <> '') { if($city <> '') { return $city . ' ' . __('in', 'veronika') . ' ' . $region . ($country_full['s_name'] <> '' ? ' (' . $country_full['s_name'] . ')' : ''); } else { return $region . ' (' . $country_full['s_name'] . ')'; } } else { if($city <> '') { return $city . ' ' . __('in', 'veronika') . ' ' . $country_full['s_name']; } else { return $country_full['s_name']; } } } else { if($region <> '') { if($city <> '') { return $city . ' ' . __('in', 'veronika') . ' ' . $region; } else { return $region; } } else { if($city <> '') { return $city; } else { return __('Location not entered', 'veronika'); } } }}
function veronika_location_format($country = null, $region = null, $city = null) { echo $country . ' - ' . $region . ' - ' . $city;
@pitbullIn that function try to echo inputsCode: [Select]function veronika_location_format($country = null, $region = null, $city = null) { echo $country . ' - ' . $region . ' - ' . $city;so first you see if there are some inputs or everything is blank.