Skip to content

Instantly share code, notes, and snippets.

@drakvuf
Created March 8, 2016 09:40
Show Gist options
  • Save drakvuf/1760a00b9e5a870d3905 to your computer and use it in GitHub Desktop.
Save drakvuf/1760a00b9e5a870d3905 to your computer and use it in GitHub Desktop.
valami: {
if (countrySelect.val() != '' && addressInput.val() != '') {
if (Number(addressInput.val()) && countrySelect.val() == 'Deutschland') {
for (var i = 0; i < merchants.length; i++) {
var merchant = merchants[i];
var mz = merchant.zip_code.toString();
var aiv = addressInput.val().toString();
if (mz.indexOf(aiv) == 0 && merchant.fullCountryName == 'Deutschland') {
address_string = merchant.zip_code + ' ' + merchant.city;
console.log(merchant.zip_code + ' ' + merchant.city);
break valami;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment