case 'dropRegions': if ($is->dropRegions()) { alert('Drop Regions OK!'); } else { alertDanger('Drop Regions Failed'); } break; case 'dropDistricts': if ($is->dropDistricts()) { alert('Drop Districts OK!'); } else { alertDanger('Drop Districts Failed'); } break; case 'dropCounties': if ($is->dropCounties()) { alert('Drop Counties OK!'); } else { alertDanger('Drop Counties Failed'); } break; //SYNC //SYNC case 'syncCountries': $insertCountryResult = $is->insertCountry($valueset); if ($insertCountryResult) { if ($insertCounrtyResult != 'INVALID-VALUESET') { alert('Sync was OK!'); } else { alertDanger('Sync Failed. Valueset "' . $valueset . '" does not exist'); }