"); banner.prop("id", "free-shipping-banner"); banner.html(bannerTemplate(countryObj)); $(".welcome-box").prepend(banner); } } else { var blacklist = ['iran', 'egypt', 'lebanon'], isBlacklisted = false; // check to see if visitor country is blacklisted or not. for ( var i = 0, o = blacklist.length; i < o; i++ ) { if ( countryName.toLowerCase() == blacklist[i].toLowerCase() ) isBlacklisted = true; } countryObj = { countryName: countryName, countryCode: countryCode, blacklisted: isBlacklisted }; $('.freeshipping.hidden-phone').html(template(countryObj)); $('.mobile-shipping-info').html(template(countryObj)); } }); Handlebars.registerHelper('bold', function (options) { return new Handlebars.SafeString( '' + options.fn(this) + ''); }); Handlebars.registerHelper('capitalize', function (str) { str = str.toLowerCase().split(' '); // will split the string delimited by space into an array of words for ( var i = 0; i < str.length; i++ ) { // str.length holds the number of occurrences of the array... str[i] = str[i].split(''); // splits the array occurrence into an array of letters str[i][0] = str[i][0].toUpperCase(); // converts the first occurrence of the array to uppercase str[i] = str[i].join(''); // converts the array of letters back into a word. } return str.join(' '); }); Handlebars.registerHelper('uppercase', function (str) { return str.toUpperCase(); });
Morakniv Eldris Pocket-Size Neck Knife Kit Fixed 2.2" 12C27 Blade…
$49.99
$39.99
Save 20%
5 (4)
ADD
In Stock
Value
ESEE Knives CAN-DT Candiru Utility Fixed 2 inch 1095 Carbon Blade, Desert Tan Powder Coat, Cordura Sheath
ESEE Knives CAN-DT Candiru Utility Fixed 2" 1095 Carbon Blade, De…
$94.80
$59.95
Save 37%
5 (4)
ADD
In Stock
Favorite
Quality
Spyderco FB24SBK2 Jumpmaster 2 Fixed 4.5 inch H1 Serrated Leaf-Shaped Blade, Black FRN Handles
Spyderco FB24SBK2 Jumpmaster 2 Fixed 4.5" H1 Serrated Leaf-Shaped…
$249.95
$149.97
Save 40%
5 (4)
ADD
In Stock
Free
Quality
Morakniv Garberg Utility Knife Fixed 4.3 inch 14C28N Blade, Black Polyamide Handle, Leather Sheath
Morakniv Garberg Utility Knife Fixed 4.3" 14C28N Blade, Black Pol…
$119.99
$94.99
Save 21%
4.5 (3)
ADD
In Stock
Favorite
Quality