');
}
//} //END NEW ITEM RANGE function
if ( $( 'span ul.CategoryDiscountList',this ).text().length > 0 ) {
$('a.thumbnail',this).append('
Sale!
');
}
else if ( $( 'a.thumbnail .product-flag-sale',this ).text().length 0 ) { /* if discount code applied or on sale */
$('a.thumbnail',this).append('
Sale!
');
}
else if ( $( '.CategoryProductSalePriceArea', this ).text().length > 0 ) { /* attrib if discount code applied or on sale */
$('a.thumbnail',this).append('
Sale!
');
}
else if ( $( '.lblSalePriceLabel', this ).text().length > 0 ) { /* BLOG if discount code applied or on sale */
$('a.thumbnail',this).append('
Sale!
');
}
else if ( $( '.pdDate', this ).text().length > 0 ) { /* if price drop */
var pdExpireDate = new Date();
pdExpireDate.setDate(pdExpireDate.getDate()-pdTimeFrame);
var strPriceDropDateTime = $(".pdDate",this).text();
var strDate = new Date(strPriceDropDateTime);
var oneDay = 24*60*60*1000; // hours*minutes*seconds*milliseconds
var diffDays = Math.round(Math.abs((strDate.getTime() - pdExpireDate.getTime())/(oneDay)));
if ( diffDays
Price Drop!
');
var strPdOldPrice = $('.pdWasPrice',this).text();
if ( strPdOldPrice != '' ) {
var twoPlacedFloat = parseFloat(strPdOldPrice).toFixed(2);
$('.CategoryProductPriceArea',this).append('
WAS: $'+twoPlacedFloat+'');
$('.lblPriceArea',this).append('
WAS: $'+twoPlacedFloat+'');
$('.ProductDetailsPriceArea',this).append('
WAS: $'+twoPlacedFloat+'').show();
}
}
else { $( '.pdDate', this ).empty(); }
}
}
if ( $( 'a.thumbnail .product-flag-sale',this ).text().length > 0 ) { // if on sale check for nested etc
var nestedCheck = "FALSE";
if ($('.pdTags:contains("NESTED")',this).length > 0) {
nestedCheck = "TRUE";
$('a.thumbnail',this).append('
');
}
if ($('.pdTags:contains("QTYDISCOUNT")',this).length > 0) {
if ( nestedCheck == "TRUE" ) {
$('div.iconImgFlag',this).html('
').css('width','60px');
}
else {
$('a.thumbnail',this).append('
');
}
}
}
else if ( $( '.pdDate', this ).text().length 0) {
nestedCheck = "TRUE";
$('a.thumbnail',this).append('
');
}
if ($('.pdTags:contains("QTYDISCOUNT")',this).length > 0) {
if ( nestedCheck == "TRUE" ) {
$('div.iconImgFlag',this).html('
').css('width','60px');
}
else {
$('a.thumbnail',this).append('
');
}
}
}
// start Amazon check
if ($('.lblPrice:contains("Amazon")',this).length > 0) {
$('div.priceDisplayCheck',this).html(" ");
$('span.lblPriceArea',this).html(" "); /* blog price list displays */
}
else if ($('.lblPrice:contains("Museum")',this).length > 0) {
$('div.priceDisplayCheck',this).html(" ");
$('span.lblPriceArea',this).html(" "); /* blog price list displays */
}
else if ($('.CategoryProductPrice:contains("Amazon")',this).length > 0) {
$('div.priceDisplayCheck',this).html(" ");
}
else if ($('.CategoryProductPrice:contains("Museum")',this).length > 0) {
$('div.priceDisplayCheck',this).html(" ");
}
else if ($('.stockStatus:contains("Out of Stock")',this).length > 0) {
$('div.priceDisplayCheck',this).html('
Out of Stock').show();
}
else if ($('.stockStatus:contains("Unavailable")',this).length > 0) {
$('div.priceDisplayCheck',this).html('
Unavailable').show();
}
else {
$('div.priceDisplayCheck',this).show();
$('.CategoryProductPriceArea',this).show();
}
});
// end Amazon check