www.contourswanspecial.com
Open in
urlscan Pro
216.242.95.228
Public Scan
URL:
https://www.contourswanspecial.com/
Submission: On November 17 via automatic, source certstream-suspicious — Scanned from DE
Submission: On November 17 via automatic, source certstream-suspicious — Scanned from DE
Form analysis
1 forms found in the DOMPOST /
<form action="/" method="post">
<div class="form element-controller">
<div class="form__span-item vse">
<script>
_AdaErrors = true;
</script>
<div role="alert" class="vse" data-vse-scroll="">
</div>
</div>
<div class="form__group">
<div class="form__icons">
<img src="/images/form-mbg.png" alt="90 Day Money Back Guarantee" loading="lazy" width="110" height="110">
<img src="/images/form-usa.png" alt="Designed in USA" loading="lazy" width="99" height="99">
<img src="/images/form-ssl.png" alt="Secure Site SSL Encryption" loading="lazy" width="106" height="106">
</div>
<!-- Step 1 -->
<div class="form__span-item form form--frame">
<fieldset class="form__fieldset" id="SelectOffer">
<h2 class="form__title">STEP 1: Choose Your Payment Plan</h2>
<div class="form__frame form__copy">
<div class="offer-group message">
<div class="offer-group__group message__select">
<div class="offer-group__offer radio-text-label offer-item">
<label for="1Pay" class="radio-text-label__label">
<input type="radio" id="1Pay" name="paymentPlan" checked="" aria-checked="true" value="S" aria-labelledby="1PayLabel" aria-controls="tvoffer-1pay mostpopular-1pay bestvalue-1pay">
<span class="radio-text-label__group">
<span class="radio-text-label__radio"></span>
<span class="radio-text-label__text">Pay In Full Today</span>
</span>
</label>
</div>
<span class="offer-group__burst">
<span class="burst">Or</span>
</span>
<div class="offer-group__offer radio-text-label offer-item">
<label for="2Pay" class="radio-text-label__label">
<input type="radio" id="2Pay" name="paymentPlan" value="M" aria-labelledby="2PayLabel" aria-controls="tvoffer-2pay mostpopular-2pay bestvalue-2pay" aria-checked="false">
<span class="radio-text-label__group">
<span class="radio-text-label__radio"></span>
<span class="radio-text-label__text">Pay in 2 Easy Monthly Installments</span>
</span>
</label>
</div>
</div>
<div class="message__group" role="alert">
<div class="message__invalid">Please choose a payment plan</div>
</div>
</div>
</div>
</fieldset>
</div>
<!-- Step 2 -->
<div class="form__span-item form form--frame">
<fieldset class="form__fieldset" id="packages">
<h2 class="form__title">STEP 2: Choose Your Package</h2>
<div class="form__frame form__copy">
<div class="offer-group offer-group--package message">
<div class="offer-group__group message__select">
<!-- TV Offer -->
<div class="offer-group__offer offer-item">
<div class="offer-item__group">
<div class="offer-item__control radio-text-label">
<div class="radio-text-label__label">
<label for="TVOffer">
<input type="radio" id="TVOffer" data-basecode="TV" name="package" value="TVS">
<span class="radio-text-label__group">
<span class="radio-text-label__radio"></span>
<span class="radio-text-label__text">
<b class="radio-text-label__title">TV Offer</b>
<span class="radio-text-label__disclaimer"> 1 Contour Swan Pillow<br> 1 <b class="radio-text-label__attention-inline">Free</b> Laundry Care Bag<br>
<b class="radio-text-label__attention-block">FREE SHIPPING</b>
</span>
</span>
</span>
</label>
</div>
</div>
<div class="offer-item__offer">
<div id="tvoffer-1pay" class="offer-item__payment element-controller__element" data-element-controller-name="1Pay" aria-hidden="false">
<span class="offer-item__strikethrough">List Price: <s>$80</s></span>
<b class="offer-item__price">$59.98</b>
</div>
<div id="tvoffer-2pay" class="offer-item__payment element-controller__element" aria-hidden="true">
<span class="offer-item__strikethrough">List Price: <s>$80</s></span>
<span>$59.98</span>
<b class="offer-item__price">2 Payments of $29.99</b>
</div>
</div>
<div class="offer-item__burst-image">
<div class="offer-item__group">
<span class="burst burst--savings">
<div class="burst__text">
<b>25%</b> off
</div>
</span>
<picture>
<img src="/images/Site6/form/product.jpg" alt="Product" width="51" height="93" loading="lazy">
</picture>
</div>
</div>
</div>
</div>
<!-- Most Popular -->
<div class="offer-group__offer offer-item">
<div class="offer-item__group">
<div class="offer-item__control radio-text-label">
<div class="radio-text-label__label">
<label for="MostPopular">
<input type="radio" id="MostPopular" data-basecode="MP" checked="" aria-checked="true" name="package" value="MPS">
<span class="radio-text-label__group">
<span class="radio-text-label__radio"></span>
<span class="radio-text-label__text">
<b class="radio-text-label__title">Most Popular</b>
<span class="radio-text-label__disclaimer"> 2 Contour Swan Pillows<br> 2 <b class="radio-text-label__attention-inline">Free</b> Laundry Care Bags<br>
<b class="radio-text-label__attention-block">FREE SHIPPING</b>
</span>
</span>
</span>
</label>
</div>
</div>
<div class="offer-item__offer">
<div id="mostpopular-1pay" class="offer-item__payment element-controller__element" data-element-controller-name="1Pay" aria-hidden="false">
<span class="offer-item__strikethrough">List Price: <s>$160</s></span>
<span>$99.96</span>
<b class="offer-item__price">Only $49.98 per pillow!</b>
</div>
<div id="mostpopular-2pay" class="offer-item__payment element-controller__element" aria-hidden="true">
<span class="offer-item__strikethrough">List Price: <s>$160</s></span>
<span>$99.96 / $49.98 per pillow</span>
<b class="offer-item__price">2 Payments of $49.98</b>
</div>
</div>
<div class="offer-item__burst-image">
<div class="offer-item__group">
<span class="burst burst--savings">
<div class="burst__text">
<b>37%</b> off
</div>
</span>
<picture>
<img src="/images/Site6/form/product.jpg" alt="Product" width="51" height="93" loading="lazy">
</picture>
<picture>
<img src="/images/Site6/form/product.jpg" alt="Product" width="51" height="93" loading="lazy">
</picture>
</div>
</div>
</div>
</div>
<!-- Best Value -->
<div class="offer-group__offer offer-item">
<div class="offer-item__group">
<div class="offer-item__control radio-text-label">
<div class="radio-text-label__label">
<label for="BestValue">
<input type="radio" id="BestValue" data-basecode="BV" name="package" value="BVS">
<span class="radio-text-label__group">
<span class="radio-text-label__radio"></span>
<span class="radio-text-label__text">
<b class="radio-text-label__title">Best Value</b>
<span class="radio-text-label__disclaimer"> 4 Contour Swan Pillows<br> 4 <b class="radio-text-label__attention-inline">Free</b> Laundry Care Bags<br>
<b class="radio-text-label__attention-block">FREE SHIPPING</b>
</span>
</span>
</span>
</label>
</div>
</div>
<div class="offer-item__offer">
<div id="bestvalue-1pay" class="offer-item__payment element-controller__element" data-element-controller-name="1Pay" aria-hidden="false">
<span class="offer-item__strikethrough">List Price: <s>$320</s></span>
<span>$179.92</span>
<b class="offer-item__price">Only $44.98 per pillow!</b>
</div>
<div id="bestvalue-2pay" class="offer-item__payment element-controller__element" aria-hidden="true">
<span class="offer-item__strikethrough">List Price: <s>$320</s></span>
<span>$179.92 / $44.98 per pillow</span>
<b class="offer-item__price">2 Payments of $89.96</b>
</div>
</div>
<div class="offer-item__burst-image">
<div class="offer-item__group">
<span class="burst burst--savings">
<div class="burst__text">
<b>45%</b> off
</div>
</span>
<picture>
<img src="/images/Site6/form/product.jpg" alt="Product" width="51" height="93" loading="lazy">
</picture>
<picture>
<img src="/images/Site6/form/product.jpg" alt="Product" width="51" height="93" loading="lazy">
</picture>
<picture>
<img src="/images/Site6/form/product.jpg" alt="Product" width="51" height="93" loading="lazy">
</picture>
<picture>
<img src="/images/Site6/form/product.jpg" alt="Product" width="51" height="93" loading="lazy">
</picture>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</fieldset>
</div>
<div id="ActionCodeDiv"><input name="ActionCode0" type="hidden" id="ActionCode0" value="MPS"><input name="ActionQuantity0" type="hidden" id="ActionQuantity0" value="1"></div>
<!-- Step 3 -->
<div class="form__span-item form form--frame">
<fieldset class="form__fieldset" id="packages">
<h2 class="form__title">STEP 3: Optional Add-Ons</h2>
<div class="form__frame form__copy">
<div class="offer-group offer-group--addon message">
<div class="offer-group__group message__select">
<div class="offer-group__offer offer-item">
<div class="offer-item__group">
<div class="offer-item__control radio-text-label">
<div class="radio-text-label__label">
<label for="pillowcase">
<input type="checkbox" id="pillowcase" data-basecode="" name="ActionCode10" value="UP2LP-3R">
<span class="radio-text-label__group">
<span class="radio-text-label__radio"></span>
<span class="radio-text-label__text">
<b class="radio-text-label__title">Custom Fit Pillowcases</b>
<span class="radio-text-label__disclaimer"> $24.99<br>
<b class="radio-text-label__attention-block">FREE SHIPPING</b>
</span>
</span>
</span>
</label>
<div class="form form--inline-combobox-label message">
<div class="form__field-label">
<label for="ActionQuantity10">
<span class="message__label">
<span class="form__error">* </span>Qty </span>
</label>
<div class="form form--select">
<div class="form__contain">
<select name="ActionQuantity10" id="CPillowcaseRadio" class="form__field dtm__restyle ddl" data-required="true" aria-required="true" aria-invalid="true" data-index="10">
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
</select>
<span class="form__field form__button">
<svg class="icon" focusable="false" role="presentation">
<use href="#icon-chevron"></use>
</svg>
</span>
</div>
</div>
<div class="message__group" role="alert">
<span class="message__invalid"> Please choose a quantity </span>
</div>
</div>
</div>
</div>
<div class="offer-item__burst-image">
<img class="offer-item__image" loading="lazy" src="/images/Site6/form/add-on-pillow.jpg" alt="Custom fit pillowcase" width="404" height="178">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</fieldset>
</div>
<div class="form__span-item form__message">
<span class="form__error">*</span>Indicates required field
</div>
<!-- Step 3 -->
<div class="form__span-item form form--frame">
<div class="form__fieldset">
<h2 class="form__title">STEP 4: Review Your Order</h2>
<div class="form__frame c-brand--form order-table reviewTable">
<div id="reviewOrder" class="c-brand--form__fieldset">
<div class="FormHeadlineL c-brand--form__headline c-brand--form__legend"><strong>STEP 2:</strong> Review Your Order</div>
<style>
.alignTextRight {
text-align: right;
}
.alignTextLeft {
text-align: left;
}
.disableToggleClick {
pointer-events: none;
}
</style>
<div class="@mv-u-pad--vert reviewTable__wrap">
<table id="orderReview" class="orderItemsTable reviewTable @mv-u-pad--vert c-brand--table--has-items">
<thead class="reviewTableHead">
<tr>
<th>Description</th>
<th>Quantity</th>
<th>Price</th>
<th>S&H</th>
</tr>
</thead>
<tbody class="reviewTableBody">
<tr>
<td data-eflex--category-label="Item">MOST POPULAR - SWAN Body Pillow (set of 2)</td>
<td data-cart-code="MPSQuantity" data-eflex--category-label="Quantity">1</td>
<td data-cart-code="MPSPrice" data-eflex--category-label="Price">$99.96</td>
<td data-cart-code="MPSShipping" data-eflex--category-label="S&H">$0.00</td>
</tr>
</tbody>
<tfoot class="reviewTableFoot alignTextRight">
<tr>
<td colspan="3">Sub Total:</td>
<td>
<label class="subtotal">$99.96</label>
</td>
</tr>
<tr>
<td colspan="3">
<label for="zc"> State Tax: <input type="tel" class="zc c-brand--form__input o-box o-shadow fx--animate o-grid--iblock u-vw--50" id="zc" name="zc" value="" placeholder="Enter Zip Code"></label>
</td>
<td>
<span class="taxtotal">$0.00</span>
</td>
</tr>
<tr>
<td colspan="3"><b>Estimated Order Total</b></td>
<td>
<span class="summary-total">$99.96</span>
</td>
</tr>
</tfoot>
</table>
</div>
<div id="orderFormReviewTableItems"></div>
</div>
<script type="text/javascript">
var _firstIndex = '';
var _firstRun = true;
var cartItems = [];
var modifierArray = [];
function getCartUrl(type) {
var m = '' == '' ? '' : 'mid=';
var a = '' == '' ? '' : 'a=';
var s = '' == '' ? '' : 's=';
var c = '' == '' ? '' : 'clickId=';
var arr = [m, a, s, c]
for (var i = 0; i < arr.length; i++) {
if (arr[i] == '') {
arr.splice(i, 1);
i--;
}
}
var qs = (m + a + s + c) == '' ? '' : ('?' + arr.join('&'));
var url = '/Cart/' + type + '/Index' + qs;
return url;
}
function loadAllItemStates() {
handleCartChange();
var preloadedItems = [];
var enableEditableQuantity = false;
if (preloadedItems.length > 0) {
handleCartChange();
} else if (!enableEditableQuantity) {
handleCartChange();
}
$.each($('[data-condition-missing][data-condition-value]:not([data-condition])'), function() {
var code = $(this).attr('data-condition-missing');
var regex = new RegExp("^" + code + "$");
var cartItem = _dtmShoppingCart.SearchItems(regex);
if ((preloadedItems.length == 0 && cartItem.length <= 0) || (preloadedItems.length > 0 && preloadedItems.indexOf(code) <= 0)) {
setDataCondition(this);
}
});
}
function checkboxToggleXor(removeItems) {
for (var i = 0; i < removeItems.length; i++) {
$('#' + removeItems[i] + '').prop('checked', false);
}
}
function radioToggleXor(removeItems) {
for (var i = 0; i < removeItems.length; i++) {
$('input[value=' + removeItems[i] + ']').prop('checked', false);
}
}
function validateTextBoxInput(element, maxQuantity) {
var value = $(element).val();
var valueInt = parseInt(value);
var newValue = 0;
if (valueInt > maxQuantity) {
newValue = maxQuantity;
} else if (isNaN(valueInt) || valueInt <= 0) {
newValue = 0;
} else {
newValue = valueInt;
}
$(element).val(newValue);
}
function isSelectorModified(selector) {
var isDataSelect = $(selector).is('select') && typeof $(selector).attr('data-select') !== "undefined";
var isModified = false;
if (isDataSelect) {
var selectedOption = $(selector).find(':selected');
isModified = ($(selector).attr('data-code-modifier') != null && $(selector).attr('data-code-modifier').length > 0 && $(selectedOption).attr('data-code-alt') != null && $(selectedOption).attr('data-code-alt').length > 0 && ($('#' +
$(selector).attr('data-code-modifier')).is(':checked') || $('[name=' + $(selector).attr('data-code-modifier') + '][value=true]').is(':checked')));
} else {
isModified = ($(selector).attr('data-code-modifier') != null && $(selector).attr('data-code-modifier').length > 0 && $(selector).attr('data-code-alt') != null && $(selector).attr('data-code-alt').length > 0 && ($('#' + $(selector)
.attr('data-code-modifier')).is(':checked') || $('[name=' + $(selector).attr('data-code-modifier') + '][value=true]').is(':checked')));
}
return isModified;
}
function AddToModifierArray(modifierName) {
var alreadyExists = false;
if (modifierArray.length > 0) {
modifierArray.forEach(function(ele) {
if (ele == modifierName) {
alreadyExists = true;
}
});
}
if (!alreadyExists) {
modifierArray.push(modifierName);
}
}
function handleModifierChangeAction(name, type) {
var modifiableSelectors = $('[data-code-modifier=' + name + ']');
var datacode = "";
var bonusArray = [];
var removeItems = [];
var firstSelectorQuantity = 0;
var quantity = 0;
switch (type) {
case 'checkbox':
var isModified = $('[name=' + name + ']').is(':checked');
break;
case 'radio':
var isModified = $('[name=' + name + ']:checked').val() == 'true';
break;
}
if (modifiableSelectors.length > 0) {
for (var i = 0; i < modifiableSelectors.length; i++) {
var element = $(modifiableSelectors[i]);
var isSelect = element.is('select') && typeof element.attr('data-select') === "undefined";
var isDataSelect = element.is('select') && typeof element.attr('data-select') !== "undefined";
var isRadioOrCB = 'radio,checkbox'.indexOf(element.attr('type')) >= 0;
if (i == 0) {
if (isSelect) {
firstSelectorQuantity = isSelect ? element.val() : 1;
} else if (isDataSelect) {
firstSelectorQuantity = element.attr('data-qty-id') != null ? $('#' + element.attr('data-qty-id')).val() : 1;
} else if (isRadioOrCB) {
if (element.is(':checked')) {
firstSelectorQuantity = element.attr('data-qty-id') != null ? $('#' + element.attr('data-qty-id')).val() : 1;
}
}
if (firstSelectorQuantity > 0) {
element = isDataSelect ? element.find(":selected") : element;
dataCode = isModified ? element.attr('data-code-alt') : isDataSelect ? element.val() : element.attr('data-code');
var bonusAddRemoveArrays = bonusItemHandler(isModified, firstSelectorQuantity, $(modifiableSelectors[i]));
bonusArray = bonusArray.concat(bonusAddRemoveArrays.bonusItems);
removeItems = removeItems.concat(bonusAddRemoveArrays.removeItems);
if (isDataSelect) {
removeItem = isModified ? element.val() : element.attr('data-code-alt');
removeItems.push(removeItem);
}
} else {
dataCode = "";
}
} else {
if (isSelect) {
quantity = isSelect ? element.val() : 1;
} else if (isDataSelect) {
quantity = element.attr('data-qty-id') != null ? $('#' + element.attr('data-qty-id')).val() : 1;
} else if (isRadioOrCB) {
if (element.is(':checked')) {
quantity = element.attr('data-qty-id') != null ? $('#' + element.attr('data-qty-id')).val() : 1;
} else {
quantity = 0;
}
}
if (quantity > 0) {
var bonusAddRemoveArrays = bonusItemHandler(isModified, quantity, $(modifiableSelectors[i]));
element = isDataSelect ? element.find(":selected") : element;
var selector = isModified ? element.attr('data-code-alt') : isDataSelect ? element.val() : element.attr('data-code');
if (dataCode == "") {
dataCode = selector;
firstSelectorQuantity = quantity;
} else {
bonusArray.push({
Id: selector,
Qty: quantity
})
}
bonusArray = bonusArray.concat(bonusAddRemoveArrays.bonusItems);
removeItems = removeItems.concat(bonusAddRemoveArrays.removeItems);
if (isDataSelect) {
removeItem = isModified ? element.val() : element.attr('data-code-alt');
removeItems.push(removeItem);
}
}
}
}
}
if (firstSelectorQuantity > 0) {
handleCartChange(dataCode, firstSelectorQuantity, null, removeItems, bonusArray, event);
}
}
function bonusItemHandler(isModified, quantity, selector) {
var bonusItemsArray = [];
var removeItemsArray = [];
if (isModified) {
//Add bonusItems
if (selector.attr('data-match-alt') != null && selector.attr('data-match-alt').length > 0) {
var tempBonusArray = selector.attr('data-match-alt').split(',');
tempBonusArray.forEach(function(ele) {
bonusItemsArray.push({
Id: ele,
Qty: quantity
});
});
}
//removebonusItems
if (selector.attr('data-match') != null && selector.attr('data-match').length > 0) {
var tempBonusArray = selector.attr('data-match').split(',');
tempBonusArray.forEach(function(ele) {
removeItemsArray.push(ele);
});
}
removeItemsArray.push(selector.attr('data-code'));
} else {
//Add bonusItems
if (selector.attr('data-match') != null && selector.attr('data-match').length > 0) {
var tempBonusArray = selector.attr('data-match').split(',');
tempBonusArray.forEach(function(ele) {
bonusItemsArray.push({
Id: ele,
Qty: quantity
});
});
}
//removebonusItems
if (selector.attr('data-match-alt') != null && selector.attr('data-match-alt').length > 0) {
var tempBonusArray = selector.attr('data-match-alt').split(',');
tempBonusArray.forEach(function(ele) {
removeItemsArray.push(ele);
});
}
if (selector.attr('data-code-alt') != null && selector.attr('data-code-alt').length > 0) {
removeItemsArray.push(selector.attr('data-code-alt'));
}
}
return {
bonusItems: bonusItemsArray,
removeItems: removeItemsArray
};
}
function CreateModifierChangeAction(modifierArray) {
if (modifierArray.length > 0) {
modifierArray.forEach(function(ele) {
var modifierName = ele;
$(document).on('change', '[name=' + modifierName + '], #' + modifierName + '', function() {
var type = $(this).attr('type');
handleModifierChangeAction(modifierName, type);
});
});
}
}
function getXorList(element) {
var xor = $(element).attr('data-code-xor');
var isDataCheckbox = $(element).attr('data-checkbox');
isDataCheckbox = (typeof isDataCheckbox !== typeof undefined);
var listItems = [];
if (xor != null && xor.length > 0) {
var allXORs = xor.split(',');
for (var i = 0; i < allXORs.length; i++) {
var singleXOR = allXORs[i];
setToggleButton(singleXOR, 'Remove');
listItems.push(singleXOR);
};
}
if (isDataCheckbox) {
checkboxToggleXor(listItems);
}
return listItems;
}
function dataMatchProductQuantity(mainItem, bonusItems, dataMatchTrue, event) {
if (dataMatchTrue) {
if ((typeof bonusItems != "undefined" && bonusItems != null && bonusItems.length > 0) && (typeof mainItem != "undefined" && mainItem != null && mainItem.length > 0)) {
var datacode = mainItem;
var bonusItems = bonusItems.split(',');
var removeBonusItems = bonusItems.slice();
var qty = $('[data-cart-code=' + datacode + 'Quantity]').children('[name^=ActionQuantity]').val();
qty = parseInt(qty);
if (!isNaN(qty)) {
if (qty > 0) {
var firstBonusItem = "";
var extraBonusItems = [];
for (var i = 0; i < bonusItems.length; i++) {
if (i == 0) {
firstBonusItem = bonusItems[i];
} else {
extraBonusItems.push({
Id: bonusItems[i],
Qty: qty
});
}
}
if (firstBonusItem != "") {
handleCartChange(firstBonusItem, qty, null, [], extraBonusItems, event);
}
} else {
handleCartChange(datacode, qty, null, removeBonusItems, null, event);
}
}
}
} else {
handleCartChange();
}
}
function OnVSCookieLoaded() {
$('input.zc').keyup(function() {
updateZip(this.value, getState(), getCountry());
});
$('select.shipOptions').change(function() {
handleCartChange();
});
$('#BillingZip, #ShippingZip').keyup(function() {
var isShipCheckboxChecked = $('#ShippingIsDifferentThanBilling').is(':checked');
if (this.id == 'ShippingZip') {
lastChangeType = 'Shipping';
} else {
lastChangeType = '';
}
if (isShipCheckboxChecked) {
$('.zc').val($('#ShippingZip').val());
updateZip($('#ShippingZip').val(), getState(), getCountry());
} else {
$('.zc').val(this.value);
updateZip(this.value, getState(), getCountry());
}
});
$('#BillingState, #ShippingState, #BillingCountry, #ShippingCountry').keyup(function() {
updateZip(getZip(), getState(), getCountry());
});
$("[name*='ActionToggle']").click(function() {
var type = $(this).attr('data-toggle-type') || 'set';
var toggleTargetIndex = $(this).attr('name').replace('ActionToggle', '');
var toggleValue = $(this).attr('data-toggle-value') || '1';
var actionCode = $('[name="ActionCode' + toggleTargetIndex + '"]') || [];
var actionQuantity = $('[name="ActionQuantity' + toggleTargetIndex + '"]') || [];
if (toggleTargetIndex == '' || actionCode.length == 0 || actionQuantity.length == 0) {
console.error('Invalid ActionToggle configuration for ' + toggleTarget);
return;
}
var currentValue = actionQuantity.val();
if (type == 'add') {
newValue = currentValue + 1;
} else {
if (currentValue == toggleValue) {
newValue = 0;
} else {
newValue = toggleValue;
}
}
actionQuantity.val(newValue);
handleCartChange();
});
$('input[name*="ActionCode"][data-default]').each(function(i, item) {
if ('radio,checkbox'.indexOf($(item).attr('type')) >= 0) {
var id = $(item).attr('id');
var name = $(item).attr('name');
var index = id.replace('ActionCode', '');
var value = $(item).val();
var labelFor = $('label[for="' + id + '"]');
if (labelFor.length > 0) {
labelFor.attr('for', 'Action' + index);
} else {
labelFor = $('#ActionCode0').parents('label');
if (labelFor.length > 0) {
labelFor.attr('for', 'Action' + index);
}
}
$(this).attr('id', 'Action' + index).attr('name', 'Action' + index);
$(this).before('<input id="' + id + '" name="' + name + '" type="hidden" value="' + value + '" data-default="' + $(item).attr('data-default') + '" data-upgrade="' + $(item).attr('data-upgrade') + '">')
}
});
$('input[data-default]').click(function() {
var index = ($(this).attr('id') || '').replace('Action', '');
var currentValue = $(this).val();
var defaultValue = $(this).attr('data-default');
var toggleValue = $(this).attr('data-upgrade');
var newValue;
if ($(this).is(":checked")) {
newValue = toggleValue;
} else {
newValue = defaultValue;
}
$(this).val(newValue);
if ($('#ActionCode' + index).length > 0) {
$('#ActionCode' + index).val(newValue);
handleCartChange();
} else {
$('a[data-code="' + currentValue + '"]').attr('data-code', newValue);
_dtmShoppingCart.UpgradeItem(currentValue, newValue);
}
});
$("[name*='ActionQuantity']").each(function(i, item) {
var index = (item.name || '').replace(/[^0-9]/g, '');
if (_firstIndex == '') {
_firstIndex = index;
}
$(item).attr('data-index', index).attr('class', ($(item).attr('class') ? $(item).attr('class') : '') + ' ddl').change(handleCartChange);
if ($('[name="ActionCode' + index + '"]').length == 0 || 'radio,checkbox'.indexOf($('[name="ActionCode' + index + '"]').attr('type')) >= 0 || $('[name="ActionCode' + index + '"]').is('select')) {
$('[name="ActionCode' + index + '"]').change(handleCartChange);
}
if ($('[name="MatchProductQuantity' + index + '"]').length == 0 || 'radio,checkbox'.indexOf($('[name="MatchProductQuantity' + index + '"]').attr('type')) >= 0) {
$('[name="MatchProductQuantity' + index + '"]').change(handleCartChange);
}
});
loadAllItemStates();
$('.ddlPromo').change(function() {
handleCartChange();
});
$("#ShippingIsDifferentThanBilling").on("click", function() {
var selector = $('#ShippingIsDifferentThanBilling').is(':checked') ? '#ShippingZip' : '#BillingZip';
var zip = $(selector).val() != undefined ? $(selector).val() : '';
updateZip(zip, getState(), getCountry());
handleCartChange();
});
$('[name^="ActionAttribute"]').change(function() {
var index = ($(this).attr('name') || '').replace('ActionAttribute', '');
var allValues = new Array();
$.each($('[name="ActionAttribute' + index + '"]'), function() {
allValues.push($(this).val());
});
if ($('[name^="ActionAttribute' + index + '"]').length == allValues.length) {
handleCartChange();
}
});
}
function getToggleButtonQty(groupName, defaultValue) {
var qty = defaultValue;
var toggleButton = $("[data-group-name='" + groupName + "'][data-code-toggle=true][data-qty-id]");
if ($(toggleButton).length > 0) {
var hasQtyId = $(toggleButton).attr("data-qty-id").length > 0;
var overrideQty = qty;
if (hasQtyId) {
var qtyId = $(toggleButton).attr("data-qty-id");
overrideQty = $("#" + qtyId).val();
}
qty = overrideQty;
}
if (defaultValue == 0) {
qty = 0;
}
return qty;
}
function setToggleButtonQty(groupName, value) {
var toggleButton = $("[data-group-name='" + groupName + "'][data-code-toggle=true][data-qty-id]");
if ($(toggleButton).length > 0) {
var hasQtyId = $(toggleButton).attr("data-qty-id").length > 0;
if (hasQtyId) {
var qtyId = $(toggleButton).attr("data-qty-id");
$("#" + qtyId).val(value);
}
}
}
function loadItemState(productCode, qty) {
var getEle = function(pc) {
var ret = null;
if ($('[name*=ActionCode][value="' + productCode + '"]').length != 0) {
ret = $('[name*=ActionCode][value="' + productCode + '"]');
} else if ($('[name*=ActionCode][data-default="' + productCode + '"]').length != 0) {
ret = $('[name*=ActionCode][data-default="' + productCode + '"]');
} else if ($('[name*=ActionCode][data-upgrade="' + productCode + '"]').length != 0) {
ret = $('[name*=ActionCode][data-upgrade="' + productCode + '"]');
} else if ($('[name*=ActionCheckbox][data-target="' + productCode + '"]').length != 0) {
ret = $('[name*=ActionCheckbox][data-target="' + productCode + '"]');
} else if ($('[name*=ActionCheckbox][data-new="' + productCode + '"]').length != 0) {
ret = $('[name*=ActionCheckbox][data-new="' + productCode + '"]');
}
return ret;
}
var ele = getEle(productCode);
var index = ($(ele).attr('name') || '').replace('ActionCode', '');
var id = productCode;
var originalId = id;
var isMod = false;
var modEle = $('[data-code][data-code-toggle=true][data-code-alt=' + id + '][data-code-modifier]');
if (modEle.length == 0) {
modEle = $('select[data-code-modifier] option[data-code-alt=' + id + '], select[data-code-modifier] option[value=' + id + ']');
if (modEle.length > 0) {
modEle = $(modEle).parent();
}
}
if (modEle.length > 0 && $('#' + modEle.attr('data-code-modifier')).length > 0) {
$('#' + modEle.attr('data-code-modifier')).prop('checked', true);
if (modEle.attr('data-code').length > 0) {
originalId = modEle.attr('data-code');
} else {
originalId = $('select[data-code-modifier] option[data-code-alt=' + id + ']').attr('value');
isMod = true;
if (originalId == null) {
originalId = $('select[data-code-modifier] option[value=' + id + ']').attr('value');
isMod = false;
}
var cbox = $('#' + $(modEle).attr('data-code-modifier'));
if (isMod) {
$(cbox).attr('checked', true);
} else {
$(cbox).attr('checked', false);
}
}
if (originalId == '') {
originalId = id;
}
}
var selEle = $('select[data-code-modifier] option[data-code-alt=' + id + '], select[data-code-modifier] option[value=' + id + ']');
if (selEle.length > 0) {
$(modEle).val(originalId);
if (typeof $(modEle).attr('data-qty-id') !== "undefined") {
var selectableEle = $('#' + $(modEle).attr('data-qty-id'));
$(selectableEle).val(qty);
}
}
var actionEle = $('[name*=ActionCode] option[value="' + id + '"]');
if (actionEle.length != 0) {
actionEle.parent().val(id);
}
if (ele == null) {
console.log("No matching elements, item state not loaded for " + id);
return;
} else if (ele.length > 1) {
console.log("Too many matching elements, item state not loaded for " + id);
return;
}
var preventCheck = false,
preventClick = false;
if (ele.attr('data-default') == id) {
if ($('#ActionQuantity' + index).length != 0) {
$('#ActionQuantity' + index).val(qty);
preventClick = true;
preventCheck = true;
}
} else if (ele.attr('data-upgrade') == id) {
ele.val(id);
if ($('#ActionQuantity' + index).length != 0) {
$('#ActionQuantity' + index).val(qty);
preventClick = true;
}
} else if (ele.attr('name').indexOf("ActionCheckbox") >= 0) {
index = ($(ele).attr('name') || '').replace('ActionCheckbox', '');
if (ele.data('new') == id) {
ele.prop('checked', true);
}
if (ele.data('target') == id) {
ele.prop('checked', false);
if ($('#ActionCode' + index).val() != ele.data('target')) {
$('#ActionCode' + index).val(ele.data('target'));
}
}
if ($('#ActionQuantity' + index).length != 0) {
$('#ActionQuantity' + index).val(qty);
preventClick = true;
}
} else if (ele.attr('type') == 'checkbox') {
ele.prop('checked', true);
}
var checkableEle = null;
var action = $('#Action' + index);
// Action
if ($(action).length > 0 && $('[name="Action' + index + '"]').length == 0 || 'radio,checkbox'.indexOf(action.attr('type')) >= 0) {
action.val(id);
checkableEle = action;
} else {
var radioWithModifier = $('input[type=radio][data-code-modifier][data-code-alt=' + id + ']');
var checkboxWithModifier = $('input[type=checkbox][data-code-modifier][data-code-alt=' + id + ']');
var radioFromGroup = $('input[type=radio][value=' + id + ']');
var radioSolo = $('input[type=radio][data-code=' + id + ']');
var selectFromGroup = $('select option[value= ' + id + ']').parent();
var checkboxGroup = $('input[type=checkbox][value=' + id + ']');
var singleCheckbox = $('input[type=checkbox][data-code=' + id + '], input[type=checkbox][data-code-alt=' + id + '] ');
var isSingleCheckbox = singleCheckbox.length > 0;
var isRadioWithModifier = $(radioWithModifier).length > 0;
var isCheckboxWithModifier = $(checkboxWithModifier).length > 0;
var isRadioSelect = $(radioFromGroup).length > 0 && $('[data-group-name=' + $(radioFromGroup).attr('name') + '][data-code-toggle=true]').length > 0;
var isRegularSelect = $(selectFromGroup).length > 0 && $('[data-group-name=' + $(selectFromGroup).attr('name') + '][data-code-toggle=true]').length > 0;
var isCheckboxSelect = $(checkboxGroup).length > 0 && $('[data-group-name=' + $(checkboxGroup).attr('name') + '][data-code-toggle=true]').length > 0;
var isRadioSolo = $(radioSolo).length > 0;
var isDataCodeSelect = $('select[data-code=' + id + '], select[data-code-alt=' + id + '] ').length > 0;
var selectItem = radioFromGroup;
//Toggle Button + Data Group + Check/Selectable Item
if (isRegularSelect || isRadioSelect || isCheckboxSelect) {
if (isRegularSelect) {
selectItem = selectFromGroup;
selectFromGroup.val(id);
} else if (isRadioSelect) {
checkableEle = radioFromGroup;
} else if (isCheckboxSelect) {
selectItem = checkboxGroup;
checkboxGroup.prop("checked", true);
}
var groupName = $(selectItem).attr('name');
var toggleButton = $('[data-group-name=' + $(selectItem).attr('name') + '][data-code-toggle=true]');
if ($(toggleButton).length > 0) {
registerEvent("ToggleButtonInitialized", function() {
setToggleButton(groupName, 'Add');
});
}
}
//Select w/ Data-code + qty
if (isDataCodeSelect) {
var selector = $('select[data-code=' + id + '], select[data-code-alt=' + id + '] ');
selector.val(qty);
var hasModifier = selector.attr('data-code-modifier') != null;
if (hasModifier) {
var modifierName = selector.attr('data-code-modifier');
var ifModifierCheckbox = 'checkbox'.indexOf($('[name=' + modifierName + ']').attr('type')) >= 0;
var ifModifierRadio = 'radio'.indexOf($('[name=' + modifierName + ']').attr('type')) >= 0;
var modifierSelected = $('select[data-code-alt=' + id + '] ');
if (modifierSelected.length > 0) {
if (ifModifierCheckbox) {
$('[name=' + modifierName + ']').attr('checked', true);
} else if (ifModifierRadio) {
$('[name=' + modifierName + '][value="true"]').attr('checked', true);
}
} else {
if (ifModifierRadio) {
$('[name=' + modifierName + '][value=false]').attr('checked', true);
} else if (ifModifierCheckbox) {
$('[name=' + modifierName + ']').attr('checked', false);
}
}
}
}
//Radio w/ Data-code only
else if (isRadioSolo) {
checkableEle = radioSolo;
//Radio w/ Radio-Modifier , setting False Radio
if (radioSolo.attr('data-code-modifier') != null && radioSolo.attr('data-code-modifier').length > 1) {
var modifierName = radioSolo.attr('data-code-modifier');
if ($('input[type=radio][name=' + modifierName + '][value=false]').length > 0) {
$('input[type=radio][name=' + modifierName + '][value=false]').prop('checked', true);
}
}
}
//Radio w/ Data-code and Data-Code-Modifier only (Alt code is selected)
else if (isRadioWithModifier) {
var modId = radioWithModifier.attr('data-code-modifier');
checkableEle = radioWithModifier;
var ifModifierCheckbox = 'checkbox'.indexOf($('[name=' + modId + '],[id=' + modId + ']').attr('type')) >= 0;
var ifModifierRadio = 'radio'.indexOf($('[name=' + modId + ']').attr('type')) >= 0;
if (ifModifierCheckbox) {
$('#' + modId + '').attr('checked', true);
}
if (ifModifierRadio) {
if ($('input[type=radio][name=' + modId + '][value=true]').length > 0) {
$('input[type=radio][name=' + modId + '][value=true]').prop('checked', true);
}
}
preventClick = true;
}
//Checkbox w/ Data-code and Data-Code-Modifier only (Alt code is selected)
else if (isCheckboxWithModifier) {
var modId = checkboxWithModifier.attr('data-code-modifier');
checkableEle = checkboxWithModifier;
preventClick = true;
$('#' + modId + '').attr('checked', true);
} else if (isSingleCheckbox) {
checkableEle = singleCheckbox;
preventClick = true;
}
}
if (checkableEle != null) {
if (!preventCheck) {
checkableEle.attr('checked', 'checked');
}
if (!preventClick) {
checkableEle.trigger('click');
}
}
//Multiple Data-Codes + Multiple Selects
var dcMultiSelect = $('[data-code*=' + id + '][data-select-id*=","][data-code-toggle=true]');
var dcMultiSelectCodes = dcMultiSelect.attr('data-code');
var dcMultiSelectId = dcMultiSelect.attr('data-select-id');
var usesDcMultiSelect = false;
if ($(dcMultiSelect).length > 0 && $('#' + $(dcMultiSelect).attr('data-select-id')).length > 0) {
if (dcMultiSelectCodes.indexOf(',') > -1) {
var dcMultiSelectCodesArray = dcMultiSelectCodes.replace(' ', '').split(',');
for (var i = 0; i < dcMultiSelectCodesArray.length; i++) {
if (id == dcMultiSelectCodesArray[i]) {
usesDcMultiSelect = true;
}
}
} else if (id == dcMultiSelectCodes) {
usesDcMultiSelect = true;
}
if (usesDcMultiSelect) {
var selectableEle;
if (dcMultiSelectId.indexOf(',') > -1) {
var dcMultiSelectors = dcMultiSelectId.split(',');
for (var i = 0; i < dcMultiSelectors.length; i++) {
if ($('#' + dcMultiSelectors[i]).length > 0) {
var dcMultiSelectProduct = $('#' + dcMultiSelectors[i]).attr('data-select-product');
if (dcMultiSelectProduct == id) {
selectableEle = $('#' + dcMultiSelectors[i]);
}
}
}
if (selectableEle.length > 0) {
$(selectableEle).val(qty);
}
registerEvent("ToggleButtonInitialized", function() {
setToggleButton(id, 'Add');
});
}
}
}
// Data-Code + Select
var dcSelect = $('[data-code=' + id + '][data-select-id][data-code-toggle=true]');
if ($(dcSelect).length <= 0) {
dcSelect = $('[data-code-alt=' + id + '][data-select-id][data-code-toggle=true]');
}
if ($(dcSelect).length > 0 && $('#' + $(dcSelect).attr('data-select-id')).length > 0) {
var selectableEle = $('#' + $(dcSelect).attr('data-select-id'));
$(selectableEle).val(qty);
registerEvent("ToggleButtonInitialized", function() {
setToggleButton(id, 'Add');
});
}
// Regular Data Code w/ Toggle Button
var toggleButton = $('[data-code=' + originalId + ']');
if (toggleButton.length > 0) {
registerEvent("ToggleButtonInitialized", function() {
setToggleButton(originalId, 'Add');
});
}
// Regular Action Code / Quantity
if ($('[name="ActionCode' + index + '"]').length == 0 || 'radio,checkbox'.indexOf(ele.attr('type')) >= 0) {
if (!ele.is(':checked')) {
ele.attr('checked', 'checked');
ele.trigger('click');
}
if ($('#ActionQuantity' + index).length > 0) {
$('#ActionQuantity' + index).val(qty);
}
} else {
$('#ActionQuantity' + index).val(qty);
}
// Set Data-Conditions
$.each($('[data-condition="' + id + '"][data-condition-value]:not([data-condition-missing])'), function() {
setDataCondition(this);
});
//Set qty value for Select with radio/checkbox
var qtySelect = $('[data-code=' + id + '][data-qty-id][type=radio],[data-code=' + id + '][data-qty-id][type=checkbox]');
if ($(qtySelect).length <= 0) {
qtySelect = $('[data-code-alt=' + id + '][data-qty-id][type=radio],[data-code-alt=' + id + '][data-qty-id][type=checkbox]');
}
if ($(qtySelect).length > 0 && $('#' + $(qtySelect).attr('data-qty-id')).length > 0) {
var selectableEle = $('#' + $(qtySelect).attr('data-qty-id'));
$(selectableEle).val(qty);
}
}
function setDataCondition(obj) {
var conditionMet = true;
var type = $(obj).is('input[type="checkbox"]') ? "Checkbox" : $(obj).is('input[type="radio"]') ? "Radio" : "Text";
var conditionValue = $(obj).attr('data-condition-value');
if ($(this).attr('data-condition-qty') != null && $(obj).attr('data-condition-qty').length >= 0) {
conditionMet = qty == parseInt($(obj).attr('data-condition-qty'));
}
if (conditionMet) {
switch (type) {
case "Checkbox":
if (conditionValue.toLowerCase() == "true") {
if (!$(obj).is(':checked')) {
$(obj).trigger('click');
}
} else if (conditionValue.toLowerCase() == "false") {
if ($(obj).is(':checked')) {
$(obj).trigger('click');
}
} else {
console.log('Condition Value for Checkboxes must be set to "true" or "false"');
}
break;
case "Radio":
$(obj).attr('checked', 'checked');
$(obj).trigger('click');
break;
case "Text":
$(obj).val(conditionValue);
break;
}
}
}
function handleCartChange() {
if (typeof(onCartChangeBegin) == "function") {
onCartChangeBegin();
}
$.get(getCartUrl('ClearCart'), {
t: new Date().getTime(),
covid: 'a395f135-2d4e-ed11-8b97-a0369f1303c7',
zipcode: getZip(),
state: getState(),
country: getCountry()
}, function() {
var html = '';
var payload = {
t: new Date().getTime(),
covid: 'a395f135-2d4e-ed11-8b97-a0369f1303c7',
zipcode: getZip(),
state: getState(),
country: getCountry()
};
var uniqueItems = getItems();
var qtyCounter = uniqueItems.length;
var toggleItems = [];
var toggleButtonCaller = null;
if (typeof(evt) !== 'undefined') {
var ev = typeof(event) === 'undefined' ? evt : evt || event;
if (ev != null && ev.currentTarget != null && $(ev.currentTarget).attr('data-code') != null) {
toggleButtonCaller = ev.currentTarget;
var tempdatacode = $(toggleButtonCaller).attr('data-code');
//Toggle Button Click
if ($(ev.currentTarget).attr('data-code-toggle') != null && $(ev.currentTarget).attr('data-code-toggle') == 'true') {
var isModified = ($(toggleButtonCaller).attr('data-code-modifier') != null && $(toggleButtonCaller).attr('data-code-modifier').length > 0 && $(toggleButtonCaller).attr('data-code-alt') != null && $(toggleButtonCaller)
.attr('data-code-alt').length > 0 && $('#' + $(toggleButtonCaller).attr('data-code-modifier')).is(':checked'));
//var tempdatacode = $(toggleButtonCaller).attr('data-code');
tempdatacode = isModified ? $(toggleButtonCaller).attr('data-code-alt') : tempdatacode;
var regex;
if (tempdatacode.indexOf(',') > -1) {
tempdatacode = tempdatacode.replace(',', ')$|^(');
regex = new RegExp("^(" + tempdatacode + ")$");
} else {
regex = new RegExp("^" + tempdatacode + "$");
}
var active = _dtmShoppingCart.SearchItems(regex).length > 0;
var $toggleButtonCaller = $(toggleButtonCaller).find('[data-code-label]').length > 0 ? $(toggleButtonCaller).find('[data-code-label]') : $(toggleButtonCaller);
$toggleButtonCaller.html(active ? 'Removing...' : 'Adding...');
} else if (overrideQty == null) {
var qtyOverride = $(toggleButtonCaller).attr('data-qty-override');
if (qtyOverride != null) {
overrideQty = qtyOverride;
} else {
var actionCode = $('[name*="ActionCode"][value="' + tempdatacode + '"]');
if (actionCode != null && actionCode.length > 0) {
var actionQty = $('[name*="ActionQuantity' + $(actionCode).attr('id').replace('ActionCode', '') + '"]');
if (actionQty != null) {
overrideQty = $(actionQty).val();
}
}
}
}
}
}
for (var index = 0; index < uniqueItems.length; index++) {
var item = uniqueItems[index];
if (item.id != '' && item.id != 'none') {
payload['Item' + index] = item.id;
payload['Qty' + index] = item.qty;
payload['Atr' + index] = item.atr;
var isGroup = false;
$("[data-group-name][data-code-toggle=true]").each(function(i, v) {
var groupName = $(this).attr('data-group-name');
$('select[name=' + groupName + '] option[value=' + item.id + ']').parent().each(function(j, z) {
isGroup = true;
if (item.qty == 0) {
setToggleButton(groupName, 'Remove');
}
toggleItems.push(groupName);
});
$('input[type=radio][name=' + groupName + '][value=' + item.id + ']').each(function(j, z) {
isGroup = true;
if (item.qty == 0) {
setToggleButton(groupName, 'Remove');
}
toggleItems.push(groupName);
});
$('input[type=checkbox][name=' + groupName + '][value=' + item.id + ']').each(function(j, z) {
isGroup = true;
if (item.qty == 0) {
setToggleButton(groupName, 'Remove');
}
toggleItems.push(groupName);
});
});
if (item.qty == 0) {
if (!isGroup) {
setToggleButton(item.id, 'Remove');
toggleItems.push(item.id);
}
}
}
}
$('.ddlPromo').each(function(index, item) {
//if digits or not a space,number, hyphen or letter, then don't let keypress work.
$(item).keydown(function(event) {
var inputValue = event.which;
if ((inputValue > 64 && inputValue < 91) // uppercase
|| (inputValue >= 96 && inputValue < 123) // lowercase + numpad numbers
|| (inputValue >= 48 && inputValue <= 57) // numbers
|| inputValue == 9 //tab
|| inputValue == 8 // backspace
|| inputValue == 46 // delete key
|| (inputValue >= 37 && inputValue <= 40)) // arrows
{
return;
}
event.preventDefault();
});
//if value contains symbol , clear field
$(item).on("input", function(e) {
var value = $(item).val();
var regex = new RegExp("[^A-Za-z0-9]");
if (regex.test(value)) {
$(item).val("");
}
});
var id = $(item).val();
payload['PromoCode'] = id;
});
$('.cartParam').each(function(index, item) {
var id;
var paramName = $(item).data('paramname') || item.name;
if ('radio'.indexOf($(item).attr('type')) >= 0) {
id = $('[name=' + item.name + ']:checked').val();
} else if ('checkbox'.indexOf($(item).attr('type')) >= 0) {
id = $('[name=' + item.name + ']').is(':checked');
} else {
id = $(item).val();
}
if (payload["param_" + paramName] == null || payload["param_" + paramName] == '') {
payload["param_" + paramName] = id;
}
});
$.post(getCartUrl('Edit'), payload, function(data) {
$('.reviewTableBody').html('');
$('#orderFormReviewTableItems').html('');
$('.futurechargerow').remove();
var totalQty = 0;
var extendedPriceTotals = [];
for (var i = 0; i < data.items.length; i++) {
var excludeFromCartCount = false;
var dataItem = data.items[i];
if (dataItem.props && dataItem.props.length > 0) {
for (var pi = 0; pi < dataItem.props.length; pi++) {
var prop = dataItem.props[pi];
dataItem.props[prop["Key"]] = prop["Value"];
if (prop["Key"] == "ExcludeFromCartCount" && prop["Value"] == 'true') {
excludeFromCartCount = true;
}
}
}
if (!excludeFromCartCount) {
totalQty += dataItem.qty;
}
var tr = renderTr(dataItem, i);
$('.reviewTableBody').append(tr);
if (dataItem.numpay > 1) {
extendedPriceTotals.push({
item: dataItem,
total: dataItem.extPrice * dataItem.qty
});
}
}
var subtotal = data.totalPrice.toFixed(2);
$('.subtotal').html('$' + subtotal);
$('.phtotal').html('$' + data.totalShipping.toFixed(2));
$('.summary-total').html('$' + data.total.toFixed(2));
$('.cartTotalQty').html(totalQty > 0 ? '(' + totalQty + ')' : '');
$('.cartTotalQtyNumbersOnly').html(totalQty > 0 ? '' + totalQty + '' : '');
setTax(data.zipdata);
if (payload['PromoCode'] && typeof hidePromoErrors === "undefined") {
displayError(data.errors);
}
if (payload['PromoCode'] && typeof(onApplyPromo) == "function") {
var promoCode = payload['PromoCode'];
var hasPromo = promoCode == data.promoCode;
var promoItem = getItemWithKeyValue(data.items, 'id', data.promoCodeTarget);
if (hasPromo && promoItem != null) {
var fireOnApplyPromo = false;
$('.ddlPromo').each(function(i, item) {
var current = $(item).attr('data-current');
if (typeof(current) == "undefined" || current != promoCode) {
$(item).attr('data-current', promoCode);
fireOnApplyPromo = true;
}
});
if (fireOnApplyPromo) {
onApplyPromo(promoCode, promoItem);
}
}
}
var futureChargesValues = new Array();
var extendedOrderTotal = (data.zipdata != null) ? data.total + data.zipdata.Amount : data.total;
for (var key in extendedPriceTotals) {
if ($.isNumeric(key)) {
var numPayments = extendedPriceTotals[key].item.numpay - ((extendedPriceTotals[key].item.price + extendedPriceTotals[key].item.shipping) !== 0 ? 1 : 0);
var monthlyTotal = parseFloat(extendedPriceTotals[key].total) / numPayments;
extendedOrderTotal += monthlyTotal;
for (var i = 0; i < numPayments; i++) {
if (futureChargesValues[i] == undefined) {
futureChargesValues[i] = monthlyTotal;
} else {
futureChargesValues[i] += monthlyTotal;
}
}
}
}
var startingLabelIndex = 2;
var tr = '<tr class="futurechargerow"><td colspan="' + 4 + '"><b>' + "Future Charges" + '</b></td></tr>';
if (futureChargesValues.length > 0) {
for (var i = 0; i < futureChargesValues.length; i++) {
tr += '<tr class="futurechargerow"><td colspan="' + 3 + '"><i>' + getFutureChargesLabels(startingLabelIndex) + '</i></td><td> $' + futureChargesValues[i].toFixed(2) + '</td></tr>';
startingLabelIndex++;
}
$('.reviewTableFoot').append(tr);
}
function getFutureChargesLabels(startingLabelIndex) {
if ("true" == "true") {
var thirtyDayMultiplier = 0;
var days = (thirtyDayMultiplier + 1) * 30;
var displayDays = (days * (startingLabelIndex - 1));
switch (startingLabelIndex) {
case 1:
var firstFutureChargeLabel = "" != "" ? "1 " + displayDays + " " : "1st Payment in " + displayDays + " days";
return firstFutureChargeLabel;
case 2:
var secondFutureChargeLabel = "" != "" ? "2 " + displayDays + " " : "2nd Payment in " + displayDays + " days";
return secondFutureChargeLabel;
case 3:
var thirdFutureChargeLabel = "" != "" ? "3 " + displayDays + " " : "3rd Payment in " + displayDays + " days";
return thirdFutureChargeLabel;
default:
var thFutureChargeLabel = "" != "" ? startingLabelIndex + " " + displayDays + " " : startingLabelIndex + "th Payment in " + displayDays + " days";
return thFutureChargeLabel;
}
} else {
switch (startingLabelIndex) {
case 1:
var firstFutureChargeLabel = "" != "" ? "1 " : "1st Payment";
return firstFutureChargeLabel;
case 2:
var secondFutureChargeLabel = "" != "" ? "2 " : "2nd Payment";
return secondFutureChargeLabel;
case 3:
var thirdFutureChargeLabel = "" != "" ? "3 " : "3rd Payment";
return thirdFutureChargeLabel;
default:
var thFutureChargeLabel = "" != "" ? startingLabelIndex + " " : startingLabelIndex + "th Payment";
return thFutureChargeLabel;
}
}
}
function getFirstPaymentLabel(price, shipping, tax) {
var shippingString = (shipping > 0) ? " + $" + shipping.toFixed(2) : "";
var taxString = (tax > 0) ? " + $" + tax.toFixed(2) : "";
if (shipping > 0 || tax > 0) {
return "Your 1st payment is " + "$" + price.toFixed(2) + shippingString + taxString;
}
return "Your 1st payment is " + price.toFixed(2);
}
function getExtendedPaySummaryLabels(startingLabelIndex) {
switch (startingLabelIndex) {
case 2:
label = "Your 2nd payment is $";
break;
case 3:
label = "Your 3rd payment is $";
break;
default:
label = "Your " + startingLabelIndex + "th payment is $";
break;
}
return label;
}
if (typeof(onCartChangeComplete) == "function") {
onCartChangeComplete();
}
if (_dtmShoppingCart != null) {
setTimeout(function() {}, 800);
var rbgroups = [];
for (var i = 0; i < toggleItems.length; i++) {
var toggleItem = toggleItems[i];
var code = toggleItem;
var regex = new RegExp("^" + toggleItem + "$");
var active = _dtmShoppingCart.SearchItems(regex).length > 0;
var isGroup = $('input[type=radio][name=' + toggleItem + ']').length > 0;
code = $('input[type=radio][value=' + toggleItem + '][name]:checked').length > 0 ? $('input[type=radio][value=' + toggleItem + '][name]:checked').attr('name') : code;
if (isGroup) {
var selectedItem = $('input[type=radio][name=' + toggleItem + ']:checked').val();
var cartRegex = new RegExp("^" + selectedItem + "$");
var cartItem = _dtmShoppingCart.SearchItems(cartRegex);
var hasItem = cartItem.length > 0;
if (hasItem) {
setToggleButtonQty(code, cartItem.TotalQuantity);
}
}
setToggleButton(code, active ? 'Add' : 'Remove');
};
$('[data-code-toggle=true][data-code]').not('[data-code-modifier]').each(function(index, item) {
var code = $(this).attr('data-code');
if (code.indexOf(',') > -1) {
var allDataCodes = code.split(',');
var datacodes = code.replace(',', ')$|^(');
var regex = new RegExp("^(" + datacodes + ")$");
var active = _dtmShoppingCart.SearchItems(regex).length > 0;
setToggleButton(code, active ? 'Add' : 'Remove');
} else {
var isCB = 'checkbox'.indexOf($(this).attr('type')) >= 0;
var code = $(this).attr('data-code');
var regex = new RegExp("^" + code + "$");
var active = _dtmShoppingCart.SearchItems(regex).length > 0;
if (isCB) {
$(this).prop("checked", active);
}
setToggleButton(code, active ? 'Add' : 'Remove');
}
});
$("[data-code-toggle=true][data-group-name]").each(function(i, item) {
var groupName = $(this).attr('data-group-name');
var isDataCheckbox = $(this).attr('data-checkbox') != null && $(this).attr('data-checkbox').length > 0;
var altCodes = "";
var hasQtySelect = $(this).attr('data-qty-id');
var selector = ($(item)[0].hasAttribute('data-select')) ? ('[name="' + groupName + '"] option[value != ""]') : ('[name="' + groupName + '"]');
var removeItems = [];
var dataCodes = $(selector).map(function() {
return this.value;
}).get().join(')$|^(');
var hasModifier = $(this).attr('data-code-modifier') != null && $(this).attr('data-code-modifier').length > 0;
if (hasModifier) {
altCodes = $('[name="' + groupName + '"]').map(function() {
return $(this).attr('data-code-alt');
}).get().join(')$|^(');
}
var regex = hasModifier ? new RegExp("^(" + dataCodes + ")$|^(" + altCodes + ")$") : new RegExp("^(" + dataCodes + ")$");
var active = _dtmShoppingCart.SearchItems(regex).length > 0;
setToggleButton(groupName, active ? 'Add' : 'Remove');
if (active && typeof hasQtySelect !== typeof undefined) {
setToggleButtonQty(groupName, _dtmShoppingCart.SearchItems(regex).TotalQuantity);
}
if (isDataCheckbox) {
$('[name="' + groupName + '"]').each(function(idx, cbx) {
var modifier = hasModifier ? $(cbx).attr('data-code-modifier') : null;
var isModified = modifier != null ? $('#' + modifier + '').is(':checked') : false;
var code = isModified ? $(cbx).attr('data-code-alt') : $(cbx).val();
var regex = new RegExp("^" + code + "$");
var active = _dtmShoppingCart.SearchItems(regex).length > 0;
$(cbx).prop("checked", active);
});
}
});
$('[data-code-toggle=true][data-code][data-code-modifier][data-code-alt]').each(function(index, item) {
var oldCode = $(this).attr('data-code');
var alt = $(this).attr('data-code-alt');
var modifier = $(this).attr('data-code-modifier');
var isChecked = $('#' + modifier).is(':checked');
var code = !isChecked ? $(this).attr('data-code') : $(this).attr('data-code-alt');
var regex = new RegExp("^" + code + "$");
var active = _dtmShoppingCart.SearchItems(regex).length > 0;
setToggleButton(oldCode, active ? 'Add' : 'Remove');
});
}
$('[data-code-toggle=true]').removeClass('disableToggleClick');
//Check if cart has any multipay items
var hasMultipay = false;
for (var i = 0; i < data.items.length; i++) {
var item = data.items[i];
if (item && item.numpay && item.numpay > 1) {
hasMultipay = true;
break;
}
}
//Toggle shipping Fields
toggleShippingFields(hasMultipay);
data.hasMultipay = hasMultipay;
_dtmShoppingCart.HasMultipay = hasMultipay;
triggerEvent("CartChange", data);
}, "json").fail(function() {
if (typeof(onCartChangeComplete) == "function") {
onCartChangeComplete();
}
$('[data-code-toggle=true]').removeClass('disableToggleClick');
});
});
}
function displayError(errorArray) {
if (errorArray && errorArray.length > 0) {
var ele = $('form').find('span[style="color: #FF0000; font-weight: bold"]');
if (ele.length == 0 && $('.vse').length > 0) {
ele = $('.vse');
}
if (_firstRun) {
if (ele.children().length) {
$.each(ele.find('li'), function(index, item) {
data.errors.push($(item).text());
});
}
}
var html = '<div class="validation-summary-errors"><span>The following errors have occured:</span>' + '<ul>';
for (var i = 0; i < errorArray.length; i++) {
if (html.indexOf(errorArray[i]) < 0) {
html += '<li>' + errorArray[i] + '</li>';
}
}
html += '</ul></div>';
if (!_firstRun) {
ele.html(html);
_dtmShoppingCart.ScrollToErrors(ele);
} else {
_firstRun = false;
}
} else if (!_firstRun) {
var ele = $('form').find('span[style="color: #FF0000; font-weight: bold"]');
if (ele.length == 0 && $('.vse').length > 0) {
ele = $('.vse');
}
ele.html('');
}
}
function setToggleButton(code, mode) {
triggerEvent("ChangeToggleButtonState", {
key: code,
state: mode
});
}
function registerEvent(evType, fn, element, useCapture) {
var elm = element || window;
if (elm.addEventListener) {
elm.addEventListener(evType, fn, useCapture || false);
} else if (elm.attachEvent) {
var r = elm.attachEvent(evType, fn);
} else {
elm[evType] = fn;
}
}
function triggerEvent(eventName, data, element) {
try {
var event;
var payload = (data && typeof(data.detail) != "undefined") ? data : (data ? {
detail: data
} : {
detail: ''
});
if (typeof window.CustomEvent === 'function') {
event = new CustomEvent(eventName, payload || {
detail: ''
});
} else if (document.createEvent) {
event = document.createEvent('HTMLEvents');
event.detail = payload.detail;
event.initEvent(eventName, true, true);
} else if (document.createEventObject) {
event = document.createEventObject();
event.detail = payload.detail;
event.eventType = eventName;
}
event.eventName = eventName;
var el = element || window;
if (el.dispatchEvent) {
el.dispatchEvent(event);
} else if (el.fireEvent && htmlEvents[eventName]) {
el.fireEvent(event.eventType, event);
} else if (el[eventName]) {
el[eventName]();
} else if (el['on' + eventName]) {
el['on' + eventName]();
}
} catch (error) {
console.log('Error executing ' + name + ' Event');
}
}
function getItemWithKeyValue(items, key, value) {
for (var i = 0; i < items.length; i++) {
var item = items[i];
if (item[key] == value) {
return item;
}
}
return null;
}
function renderTr(dataItem, i) {
if (!dataItem.props["HideProduct"]) {
var tr = '<tr>';
tr += '<td data-eflex--category-label="Item">' + dataItem.name + '</td>';
tr += '<td data-cart-code="' + dataItem.code + 'Quantity" data-eflex--category-label="Quantity">' + dataItem.qty + '</td>';
tr += '<td data-cart-code="' + dataItem.code + 'Price" data-eflex--category-label="Price">$' + (dataItem.reportPrice * dataItem.qty).toFixed(2) + '</td>';
tr += '<td data-cart-code="' + dataItem.code + 'Shipping" data-eflex--category-label="S&H">$' + (dataItem.shipping * dataItem.qty).toFixed(2) + '</td>';
tr += '</tr>';
return tr;
}
return '';
}
function updateTr(dataItem, i) {
var qtyTd = $("[data-cart-code='" + dataItem.code + "Quantity']");
if (qtyTd.length != 0) {
var Quantity = qtyTd.children("[name*='ActionQuantity']")[0];
$(Quantity).val(dataItem.qty);
if (qtyTd.attr('data-cart-noedit')) {
qtyTd.html(dataItem.qty);
qtyTd.append(Quantity);
}
$("[data-cart-code='" + dataItem.code + "Price']").html('$' + (dataItem.price * dataItem.qty).toFixed(2) + '');
$("[data-cart-code='" + dataItem.code + "Shipping']").html('$' + (dataItem.shipping * dataItem.qty).toFixed(2) + '');
} else {
i = $('#orderFormReviewTableItems').children("input").length;
var tr = renderTr(dataItem, i);
$('.reviewTableBody').append(tr);
}
}
function updateCartItems(dataItems) {
$(dataItems).each(function(index, item) {
var exists = false;
$(cartItems).each(function(i, cartItem) {
if (cartItem.code == item.code) {
cartItem.added = true;
exists = true;
return;
}
});
if (!exists) {
cartItems.push({
code: item.code,
added: true
})
};
});
$(cartItems).each(function(index, cartItem) {
var exists = false;
$(dataItems).each(function(i, item) {
if (cartItem.code == item.code) {
exists = true;
return;
}
});
cartItem.added = exists;
});
}
function updateRemovedTr() {
$(cartItems).each(function(index, item) {
if (!item.added) {
var qtyTd = $("[data-cart-code='" + item.code + "Quantity']");
var Quantity = qtyTd.children("[name*='ActionQuantity']")[0];
$(Quantity).val('0');
if (qtyTd.attr('data-cart-noedit')) {
qtyTd.html('0');
qtyTd.append(Quantity);
}
$("[data-cart-code='" + item.code + "Price']").html('$' + (0).toFixed(2) + '');
$("[data-cart-code='" + item.code + "Shipping']").html('$' + (0).toFixed(2) + '');
}
});
}
function setTax(data) {
if (data != null) {
var zip = $('.zc').val();
var shipZip = $('#ShippingZip').val();
var billZip = $('#BillingZip').val();
var shipCity = $('#ShippingCity').val();
var billCity = $('#BillingCity').val();
var shipState = $('#ShippingState').val();
var billState = $('#BillingState').val();
var shipCountry = $('#ShippingCountry').val();
var billCountry = $('#BillingCountry').val();
if ($('#ShippingIsDifferentThanBilling').is(':checked') && lastChangeType == 'Shipping') {
if (data.City != '' && data.City != null && shipCity == "") {
$('#ShippingCity').val(data.City);
}
if (data.CountryCode != '' && data.CountryCode != null && shipCountry == "") {
$('#ShippingCountry').val(data.CountryCode);
}
if (data.StateCode != '' && data.StateCode != null && shipState == "") {
$('#ShippingState').val(data.StateCode);
}
if (shipZip == "") {
$('#ShippingZip').val(zip);
}
} else {
if (data.City != '' && data.City != null && billCity == "") {
$('#BillingCity').val(data.City);
}
if (data.CountryCode != '' && data.CountryCode != null && billCountry == "") {
$('#BillingCountry').val(data.CountryCode);
}
if (data.StateCode != '' && data.StateCode != null && billState == "") {
$('#BillingState').val(data.StateCode);
}
if (billZip == "") {
$('#BillingZip').val(zip);
}
}
$('.taxtotal').html('$' + data.Amount.toFixed(2));
$('.summary-total').html('$' + data.TaxTotal.toFixed(2));
}
}
function getZip() {
return $('#zc').val();
}
function getState() {
return $('#ShippingIsDifferentThanBilling').is(':checked') ? $('#ShippingState').val() : $('#BillingState').val();
}
function getCountry() {
return $('#ShippingIsDifferentThanBilling').is(':checked') ? $('#ShippingCountry').val() : $('#BillingCountry').val();
}
var currentzipcode = '',
lastChangeType = '';
function updateZip(zipcode, state, country) {
if (zipcode != '' && zipcode != currentzipcode && zipcode.length >= 5) {
currentzipcode = zipcode;
$('.zc').val(zipcode);
handleCartChange();
}
}
function getItems(items) {
var uniqueItems = new Array();
$("[name*='ActionQuantity']").each(function(index, item) {
var id;
var itemIndex = (item.getAttribute('data-index') ? item.getAttribute('data-index') : (item.id || '').replace('ActionQuantity', ''));
if ($('[name="ActionCode' + itemIndex + '"]').length == 0 || 'radio,checkbox'.indexOf($('[name="ActionCode' + itemIndex + '"]').attr('type')) >= 0) {
if ($('[name="ActionCode' + itemIndex + '"][data-upgrade]').length != 0) {
id = $('[name="ActionCode' + itemIndex + '"]').val();
} else {
id = $('[name="ActionCode' + itemIndex + '"]:checked').val();
}
} else {
id = $('[name="ActionCode' + itemIndex + '"]').val();
if ($('[name="ActionCode' + itemIndex + '"]').attr('data-checkbox')) {
var checkBoxName = $('[name="ActionCode' + itemIndex + '"]').attr('name').replace('Code', 'Checkbox');
var checkBoxEle = $('[name="' + checkBoxName + '"]');
if (checkBoxEle.attr('data-new') == id) {
checkBoxEle.prop('checked', true);
}
}
}
if (id != null && id != '' && id != 'none') {
var qty = $(item).val();
var atr;
if ($('[name="ActionAttribute' + itemIndex + '"]').length == 0 || 'radio,checkbox'.indexOf($('[name="ActionAttribute' + itemIndex + '"]').attr('type')) >= 0) {
if ($('[name="ActionAttribute' + itemIndex + '"]').length == 1) {
atr = $('[name="ActionAttribute' + itemIndex + '"]:checked').val();
} else {
var allValues = new Array();
$.each($('[name="ActionAttribute' + itemIndex + '"]:checked'), function() {
allValues.push($(this).val());
});
atr = allValues.join(',');
}
} else {
if ($('[name="ActionAttribute' + itemIndex + '"]').length == 1) {
atr = $('[name="ActionAttribute' + itemIndex + '"]').val();
} else {
var allValues = new Array();
$.each($('[name="ActionAttribute' + itemIndex + '"]'), function() {
allValues.push($(this).val());
});
atr = allValues.join(',');
}
}
if (uniqueItems[id]) {
for (var ui = 0; ui < uniqueItems.length; ui++) {
var uitem = uniqueItems[ui];
if (uitem.id == id) {
uitem.qty += parseInt(qty);
break;
}
}
} else {
uniqueItems[id] = true;
uniqueItems[uniqueItems.length] = {
id: id,
qty: parseInt(qty),
atr: atr
};
}
if ($('[name="MatchProductQuantity' + itemIndex + '"]').length == 0 || 'radio,checkbox'.indexOf($('[name="MatchProductQuantity' + itemIndex + '"]').attr('type')) >= 0) {
var match = $('[name="MatchProductQuantity' + itemIndex + '"]:checked').val();
} else {
var match = $('[name="MatchProductQuantity' + itemIndex + '"]').val();
}
if (typeof match != "undefined" && match.length > 0) {
if (uniqueItems[match]) {
for (var ui = 0; ui < uniqueItems.length; ui++) {
var uitem = uniqueItems[ui];
if (uitem.id == match) {
uitem.qty += parseInt(qty);
break;
}
}
} else {
uniqueItems[match] = true;
uniqueItems[uniqueItems.length] = {
id: match,
qty: parseInt(qty),
atr: atr
};
}
}
} else {
console.log('id was blank, skipping.')
}
});
return uniqueItems;
}
var DtmShoppingCart = function() {
var self = this;
self.scrollToTopPosition = parseFloat("-200");
self.CurrentErrors = [];
self.Count = function() {
return self.Items().length;
}
self.Items = function() {
return getItems();
};
self.HasMultipay = false;
self.SearchItems = function(pattern) {
var items = getItems();
var results = [];
results["TotalQuantity"] = 0;
for (var i = 0; i < items.length; i++) {
var item = items[i];
if (new RegExp(pattern).test(item.id)) {
results[results.length] = item;
results[item.id] = item;
results["TotalQuantity"] += item.qty;
}
}
return results;
};
self.SetItems = function(items) {
setItems(items);
}
self.AddErrors = function(errorsArray) {
var allErrors = self.CurrentErrors.concat(errorsArray);
var uniqueErrors = [];
for (var i = 0, l = allErrors.length; i < l; i++) {
if (uniqueErrors.indexOf(allErrors[i]) === -1) {
uniqueErrors.push(allErrors[i]);
}
}
self.DisplayErrors(uniqueErrors, true);
self.ScrollToErrors();
};
self.RemoveErrors = function(errorsArray) {
var currentErrors = self.CurrentErrors;
var uniqueErrors = [];
for (var i = 0, l = currentErrors.length; i < l; i++) {
var currentError = currentErrors[i];
var alreadyExists = false;
for (var j = 0; j < errorsArray.length; j++) {
var toRemoveError = errorsArray[j];
if (currentErrors.indexOf(toRemoveError) > -1 && currentError == toRemoveError) {
alreadyExists = true;
}
}
if (uniqueErrors.indexOf(currentError) === -1 && !alreadyExists) {
uniqueErrors.push(currentError);
}
}
self.DisplayErrors(uniqueErrors, true);
};
self.ScrollToErrors = function(customElement) {
if (self.CurrentErrors.length > 0) {
var ele = getErrorElement();
$.scrollTo(ele, {
top: self.scrollToTopPosition
});
} else if (customElement) {
$.scrollTo(customElement, {
top: self.scrollToTopPosition
});
}
};
function getErrorElement() {
var ele = $('form').find('span[style="color: #FF0000; font-weight: bold"]');
if (ele.length == 0) {
//For IE
ele = $('form').find('span[style="color: rgb(255, 0, 0); font-weight: bold;"]');
}
if (ele.length == 0 && $('.vse').length > 0) {
ele = $('.vse');
}
return ele;
}
self.UpgradeItem = function(currentCode, newCode) {
var items = self.Items();
for (var i = 0; i < items.length; i++) {
var item = items[i];
if (item.id == currentCode) {
item.id = newCode;
break;
}
}
self.SetItems(items);
};
self.DisplayErrors = function(errorsArray, show) {
if (errorsArray && errorsArray.length > 0) {
var ele = getErrorElement();
if (_firstRun) {
if (ele.children().length) {
$.each(ele.find('li'), function(index, item) {
errorsArray.push($(item).text());
});
}
}
var html = '<div class="validation-summary-errors"><span>The following errors have occured:</span>' + '<ul>';
for (var i = 0; i < errorsArray.length; i++) {
if (html.indexOf(errorsArray[i]) < 0) {
html += '<li>' + errorsArray[i] + '</li>';
}
}
html += '</ul></div>';
self.CurrentErrors = errorsArray;
if (!_firstRun || show) {
ele.html(html);
self.ScrollToErrors();
} else {
_firstRun = false;
}
} else if (!_firstRun || show) {
var ele = getErrorElement();
ele.html('');
self.CurrentErrors = [];
}
};
};
var _dtmShoppingCart = new DtmShoppingCart();
//Disable and hide Shipping checkbox if isMultipay = true
function toggleShippingFields(isMultipay) {
let shippingCbx = $("[name='ShippingIsDifferentThanBilling']:checkbox");
let shippingLabel = $("#ShippingIsSame");
if (!shippingLabel) {
shippingLabel = shippingCbx.parent().parent();
}
if (isMultipay) {
if (shippingCbx.is(":checked")) {
shippingCbx.prop("checked", false);
toggleShipping();
}
shippingCbx.prop("disabled", true);
shippingLabel.hide();
} else if ($('#otCARD').length == 0 || $('#otCARD').is(':checked')) {
shippingCbx.prop("disabled", false);
shippingLabel.show();
}
}
registerEvent("PaymentOptionSelected", function() {
if (_dtmShoppingCart) {
toggleShippingFields(_dtmShoppingCart.HasMultipay);
}
});
var shippingPrices = {};
</script>
</div>
</div>
</div>
<div class="form__item">
<div class="form__group-section">
<!-- Step 4 -->
<div class="form__item form__section" data-viewport="">
<div class="view__scroll form form--frame">
<fieldset class="form__fieldset">
<h2 class="form__title">STEP 5: Select Payment Type</h2>
<div class="form__frame">
<!-- Card Type -->
<div class="form__span-item form message">
<div class="form__group">
<div id="cc" class="form__group form__payment-icons"><img id="visaImg" src="/shared/images/payment/visa.svg?v=6.0.1689.1516" alt="visa accepted." width="37"><img id="mastercardImg"
src="/shared/images/payment/mastercard.svg?v=6.0.1689.1516" alt="mastercard accepted." width="37"><img id="amexImg" src="/shared/images/payment/amex.svg?v=6.0.1689.1516" alt="amex accepted." width="37"><img id="discoverImg"
src="/shared/images/payment/discover.svg?v=6.0.1689.1516" alt="discover accepted." width="37"></div>
</div>
</div>
<div id="paymentInformation" data-express-checkout-order-type="CARD" class="form__span-item">
<div class="form__group">
<div role="alert" id="vse-payment" data-vse-scroll=""></div>
<!-- Card Number -->
<div class="form__span-item form message">
<div class="form__field-label">
<input type="tel" name="CardNumber" id="CardNumber" placeholder="#### #### #### ####" data-required="true" autocomplete="cc-number" class="dtm__restyle form__field " value="" aria-required="true" aria-invalid="true">
<label for="CardNumber" class="message__label">
<span class="form__error">* </span>Card Number </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a valid card number. </span>
</span>
<input type="hidden" id="CardType" name="CardType">
</div>
</div>
<!-- Card Expiration Month -->
<div id="CardExpirationCt" class="form message">
<div class="form__field-label">
<div class="form form--select message__select">
<div class="form__contain">
<select autcomplete="cc-exp-month" class="form__field dtm__restyle" data-required="true" id="CardExpirationMonth" name="CardExpirationMonth" aria-required="true" aria-invalid="true">
<option value="01">01 - Jan</option>
<option value="02">02 - Feb</option>
<option value="03">03 - Mar</option>
<option value="04">04 - Apr</option>
<option value="05">05 - May</option>
<option value="06">06 - Jun</option>
<option value="07">07 - Jul</option>
<option value="08">08 - Aug</option>
<option value="09">09 - Sep</option>
<option value="10">10 - Oct</option>
<option value="11">11 - Nov</option>
<option value="12">12 - Dec</option>
</select>
<span class="form__field form__button">
<svg class="icon">
<use href="#icon-chevron"></use>
</svg>
</span>
</div>
</div>
<label for="CardExpirationMonth" class="message__label"><span class="requiredIcon">*</span>Expiration Date<span class="labelColon">:</span></label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please choose an expiration month. </span>
</span>
</div>
</div>
<!-- Card Expiration Year -->
<div id="CardExpirationYearCt" class="form message">
<div class="form__field-label">
<div class="form form--select message__select">
<div class="form__contain">
<select autocomplete="cc-exp-year" class="form__field dtm__restyle" id="CardExpirationYear" name="CardExpirationYear" data-required="true">
<option value="2022">2022</option>
<option value="2023">2023</option>
<option value="2024">2024</option>
<option value="2025">2025</option>
<option value="2026">2026</option>
<option value="2027">2027</option>
<option value="2028">2028</option>
<option value="2029">2029</option>
<option value="2030">2030</option>
<option value="2031">2031</option>
<option value="2032">2032</option>
</select>
<span class="form__field form__button">
<svg class="icon">
<use href="#icon-chevron"></use>
</svg>
</span>
</div>
</div>
<label for="CardExpirationYear" class="message__label">
<span class="form__error">* </span>Card Expiration Year </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter an expiration year. </span>
</span>
</div>
</div>
<!-- Card CVV2 -->
<div id="CardCVV2Ct" class="form__span-item form message">
<div class="form__field-label form__cvv">
<input type="tel" name="CardCvv2" id="CardCvv2" autocomplete="cc-csc" placeholder="###" data-required="true" class="dtm__restyle form__field " value="" aria-required="true" aria-invalid="true">
<label for="CardCvv2" class="message__label">
<span class="form__error">* </span>CVV2 </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a CVV number. </span>
</span>
<a data-modal-dialog-id="cvv2-modal-dialog" data-modal-dialog-actor="open" data-modal-dialog-iframe="" data-modal-dialog-title="About CVV2" href="/shared/cvv.html" title="Learn What is CVV2" id="cvv2" class="account__link form__link">What is CVV2?</a>
</div>
</div>
</div>
</div>
</div>
</fieldset>
</div>
</div>
<div id="billingInformation" class="form__item form__section" data-express-checkout-order-type="CARD">
<div class="form__copy view__scroll">
<div class="form form--frame">
<!-- Step 5 -->
<fieldset class="form__fieldset">
<h2 class="form__title">STEP 6: Billing Address</h2>
<div class="form__span-item form__frame">
<div class="form__group">
<!-- First Name -->
<div class="form message">
<div class="form__field-label">
<input type="text" title="First name can only contain letter characters" data-required="true" autocomplete="billing given-name" name="BillingFirstName" id="BillingFirstName" placeholder="*First Name"
class="dtm__restyle form__field o-grid__col @xs-u-vw--100" value="" aria-required="true" aria-invalid="true">
<label for="BillingFirstName" class="message__label">
<span class="form__error">* </span>First Name </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a first name. </span>
</span>
</div>
</div>
<!-- Last Name -->
<div class="form message">
<div class="form__field-label">
<input type="text" name="BillingLastName" id="BillingLastName" placeholder="*Last Name" data-required="true" autocomplete="billing family-name" class="dtm__restyle form__field o-grid__col @xs-u-vw--100" value=""
aria-required="true" aria-invalid="true">
<label for="BillingLastName" class="message__label">
<span class="form__error">* </span>Last Name </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a last name. </span>
</span>
</div>
</div>
<!-- Street -->
<div class="form__span-item form message">
<div class="form__field-label">
<input type="text" name="BillingStreet" id="BillingStreet" placeholder="*Address" data-required="true" autocomplete="section-bill billing address-line1"
class="dtm__restyle form__field o-grid__col @xs-u-vw--100 ui-autocomplete-input" value="" aria-required="true" aria-invalid="true">
<label for="BillingStreet" class="message__label">
<span class="form__error">* </span>Address </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter an address. </span>
</span>
</div>
</div>
<!-- Street 2 -->
<div class="form__span-item form message">
<div class="form__field-label">
<input type="text" name="BillingStreet2" id="BillingStreet2" placeholder="Suite / Apt" aria-describedby="BillingStreet2Description" autocomplete="billing address-line2"
class="dtm__restyle form__field o-grid__col @xs-u-vw--100" value="">
<label for="BillingStreet2" class="message__label"> Address 2 </label>
<span class="message__group" role="alert">
<small id="BillingStreet2Description" class="message__label"> Example: Suite / Apt., etc. </small>
<span class="message__invalid"> Please enter an address. </span>
</span>
</div>
</div>
<!-- City -->
<div class="form__take-some form message">
<div class="form__field-label">
<input type="text" name="BillingCity" id="BillingCity" placeholder="*City" data-required="true" autocomplete="billing address-level2" class="dtm__restyle form__field o-grid__col @xs-u-vw--100" value="" aria-required="true"
aria-invalid="true">
<label for="BillingCity" class="message__label">
<span class="form__error">* </span>City </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a city. </span>
</span>
</div>
</div>
<!-- State -->
<div class="form__take-some form message">
<div class="form__field-label" id="billStateParent">
<div class="form form--select message__select">
<div class="form__contain">
<select autocomplete="billing address-level1" class="dtm__restyle form__field" data-required="true" id="BillingState" name="BillingState" aria-required="true" aria-invalid="true">
<option value="AL">Alabama</option>
<option value="AZ">Arizona</option>
<option value="AR">Arkansas</option>
<option value="CA">California</option>
<option value="CO">Colorado</option>
<option value="CT">Connecticut</option>
<option value="DE">Delaware</option>
<option value="DC">District Of Columbia</option>
<option value="FL">Florida</option>
<option value="GA">Georgia</option>
<option value="ID">Idaho</option>
<option value="IL">Illinois</option>
<option value="IN">Indiana</option>
<option value="IA">Iowa</option>
<option value="KS">Kansas</option>
<option value="KY">Kentucky</option>
<option value="LA">Louisiana</option>
<option value="ME">Maine</option>
<option value="MD">Maryland</option>
<option value="MA">Massachusetts</option>
<option value="MI">Michigan</option>
<option value="MN">Minnesota</option>
<option value="MS">Mississippi</option>
<option value="MO">Missouri</option>
<option value="MT">Montana</option>
<option value="NE">Nebraska</option>
<option value="NV">Nevada</option>
<option value="NH">New Hampshire</option>
<option value="NJ">New Jersey</option>
<option value="NM">New Mexico</option>
<option value="NY">New York</option>
<option value="NC">North Carolina</option>
<option value="ND">North Dakota</option>
<option value="OH">Ohio</option>
<option value="OK">Oklahoma</option>
<option value="OR">Oregon</option>
<option value="PA">Pennsylvania</option>
<option value="RI">Rhode Island</option>
<option value="SC">South Carolina</option>
<option value="SD">South Dakota</option>
<option value="TN">Tennessee</option>
<option value="TX">Texas</option>
<option value="UT">Utah</option>
<option value="VT">Vermont</option>
<option value="VA">Virginia</option>
<option value="WA">Washington</option>
<option value="WV">West Virginia</option>
<option value="WI">Wisconsin</option>
<option value="WY">Wyoming</option>
</select>
<span class="form__field form__button">
<svg class="icon">
<use href="#icon-chevron"></use>
</svg>
</span>
</div>
</div>
<label for="BillingState" class="message__label">
<span class="form__error">* </span>State </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please choose a state. </span>
</span>
</div>
</div>
<!-- Zip Code -->
<div class="form__take-some form message">
<div class="form__field-label">
<input type="tel" name="BillingZip" id="BillingZip" placeholder="*Zip Code" data-required="true" autocomplete="billing postal-code" class="dtm__restyle form__field o-grid__col @xs-u-vw--100" value="" aria-required="true"
aria-invalid="true">
<label for="BillingZip" class="message__label">
<span class="form__error">* </span>Zip Code </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a zip code. </span>
</span>
</div>
</div>
<!-- Country -->
<div class="form message" style="display:none">
<div class="form__field-label">
<div class="form form--select message__select">
<div class="form__contain" style="display: none;">
<span class="form__field form__button">
<svg class="icon">
<use href="#icon-chevron"></use>
</svg>
</span>
</div>
</div>
<label for="BillingCountry" class="message__label">
<span class="form__error">* </span>Country </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please choose a country. </span>
</span>
</div>
</div>
<!-- Phone -->
<div class="form__span-item form message">
<div class="form__field-label">
<input type="tel" name="Phone" id="Phone" placeholder="*Phone" data-required="true" autocomplete="billing tel" class="dtm__restyle form__field o-grid__col @xs-u-vw--100" value="" aria-required="true" aria-invalid="true">
<label for="Phone" class="message__label">
<span class="form__error">* </span>Phone </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a phone number. </span>
</span>
</div>
</div>
<!-- Email -->
<div class="form__span-item form message">
<div class="form__field-label">
<input type="email" name="Email" id="Email" title="Format example: someone@someplace.com" data-required="true" autocomplete="billing email" placeholder="*Email" class="dtm__restyle form__field o-grid__col @xs-u-vw--100"
value="" aria-required="true" aria-invalid="true">
<label for="Email" class="message__label">
<span class="form__error">* </span>Email </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter an email address. </span>
</span>
</div>
</div>
</div>
</div>
</fieldset>
</div>
<div class="form message" id="ShippingIsSame">
<div class="form__checkbox-label form__copy">
<input type="checkbox" id="ShippingIsDifferentThanBilling" name="ShippingIsDifferentThanBilling" value="true" aria-labelledby="ShippingIsDifferentThanBillingLabel">
<input name="ShippingIsDifferentThanBilling" type="hidden" value="false">
<label for="ShippingIsDifferentThanBilling" class="form__label">
<span class="form__checkbox"></span>
<span id="ShippingIsDifferentThanBillingLabel">Check if your shipping address is different than your billing address.</span>
</label>
<div id="shippingInformation" class="form__span-item form form--frame" style="display: none;">
<fieldset class="form__fieldset">
<h2 class="form__title">STEP 7: Shipping Address</h2>
<div class="form__span-item form__frame">
<div class="form__group">
<!-- First Name -->
<div class="form message">
<div class="form__field-label">
<input type="text" title="Name can only contain letters" data-required="true" autocomplete="shipping given-name" name="ShippingFirstName" id="ShippingFirstName" placeholder="*First Name"
class="dtm__restyle form__field shipping__field o-grid__col @xs-u-vw--100" value="" aria-required="true" aria-invalid="true">
<label for="ShippingFirstName" class="message__label">
<span class="form__error">* </span>First Name </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a first name. </span>
</span>
</div>
</div>
<!-- Last Name -->
<div class="form message">
<div class="form__field-label">
<input type="text" name="ShippingLastName" id="ShippingLastName" placeholder="*Last Name" data-required="true" autocomplete="shipping family-name"
class="dtm__restyle form__field shipping__field o-grid__col @xs-u-vw--100" value="" aria-required="true" aria-invalid="true">
<label for="ShippingLastName" class="message__label">
<span class="form__error">* </span>Last Name </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a last name. </span>
</span>
</div>
</div>
<!-- Street -->
<div class="form__span-item form message">
<div class="form__field-label">
<input type="text" name="ShippingStreet" id="ShippingStreet" placeholder="*Address" data-required="true" autocomplete="section-ship shipping address-line1"
class="dtm__restyle form__field shipping__field o-grid__col @xs-u-vw--100 ui-autocomplete-input" value="" aria-required="true" aria-invalid="true">
<label for="ShippingStreet" class="message__label">
<span class="form__error">* </span>Address </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter an address. </span>
</span>
</div>
</div>
<!-- Street 2 -->
<div class="form__span-item form message">
<div class="form__field-label">
<input type="text" name="ShippingStreet2" id="ShippingStreet2" autocomplete="shipping address-line2" placeholder="Suite / Apt" aria-describedby="ShippingStreet2Description"
class="dtm__restyle form__field shipping__field o-grid__col @xs-u-vw--100" value="">
<label for="ShippingStreet2" class="message__label"> Address 2 </label>
<span class="message__group" role="alert">
<small id="ShippingStreet2Description" class="message__label">Example: Street / Apt., etc.</small>
<span class="message__invalid"> Please enter an address. </span>
</span>
</div>
</div>
<!-- City -->
<div class="form__take-some form message">
<div class="form__field-label">
<input type="text" name="ShippingCity" id="ShippingCity" placeholder="*City" autocomplete="shipping address-level2" data-required="true" class="dtm__restyle form__field shipping__field o-grid__col @xs-u-vw--100"
value="" aria-required="true" aria-invalid="true">
<label for="ShippingCity" class="message__label">
<span class="form__error">* </span>City </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a city. </span>
</span>
</div>
</div>
<!-- State -->
<div class="form__take-some form message">
<div class="form__field-label" id="shipStateParent">
<div class="form form--select message__select">
<div class="form__contain">
<select autocomplete="shipping address-level1" class="dtm__restyle form__field shipping__field" id="ShippingState" name="ShippingState">
<option value="AL">Alabama</option>
<option value="AZ">Arizona</option>
<option value="AR">Arkansas</option>
<option value="CA">California</option>
<option value="CO">Colorado</option>
<option value="CT">Connecticut</option>
<option value="DE">Delaware</option>
<option value="DC">District Of Columbia</option>
<option value="FL">Florida</option>
<option value="GA">Georgia</option>
<option value="ID">Idaho</option>
<option value="IL">Illinois</option>
<option value="IN">Indiana</option>
<option value="IA">Iowa</option>
<option value="KS">Kansas</option>
<option value="KY">Kentucky</option>
<option value="LA">Louisiana</option>
<option value="ME">Maine</option>
<option value="MD">Maryland</option>
<option value="MA">Massachusetts</option>
<option value="MI">Michigan</option>
<option value="MN">Minnesota</option>
<option value="MS">Mississippi</option>
<option value="MO">Missouri</option>
<option value="MT">Montana</option>
<option value="NE">Nebraska</option>
<option value="NV">Nevada</option>
<option value="NH">New Hampshire</option>
<option value="NJ">New Jersey</option>
<option value="NM">New Mexico</option>
<option value="NY">New York</option>
<option value="NC">North Carolina</option>
<option value="ND">North Dakota</option>
<option value="OH">Ohio</option>
<option value="OK">Oklahoma</option>
<option value="OR">Oregon</option>
<option value="PA">Pennsylvania</option>
<option value="RI">Rhode Island</option>
<option value="SC">South Carolina</option>
<option value="SD">South Dakota</option>
<option value="TN">Tennessee</option>
<option value="TX">Texas</option>
<option value="UT">Utah</option>
<option value="VT">Vermont</option>
<option value="VA">Virginia</option>
<option value="WA">Washington</option>
<option value="WV">West Virginia</option>
<option value="WI">Wisconsin</option>
<option value="WY">Wyoming</option>
</select>
<span class="form__field form__button">
<svg class="icon">
<use href="#icon-chevron"></use>
</svg>
</span>
</div>
</div>
<label for="ShippingState" class="message__label">
<span class="form__error">* </span>State </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please choose a state. </span>
</span>
</div>
</div>
<!-- Zip Code -->
<div class="form__take-some form message">
<div class="form__field-label">
<input type="tel" name="ShippingZip" id="ShippingZip" placeholder="*Zip Code" autocomplete="shipping postal-code" data-required="true" class="dtm__restyle form__field o-grid__col @xs-u-vw--100" value=""
aria-required="true" aria-invalid="true">
<label for="ShippingZip" class="message__label">
<span class="form__error">* </span>Zip Code </label>
<span class="message__group" role="alert">
<span class="message__invalid"> Please enter a zip code. </span>
</span>
</div>
</div>
<!-- Country -->
<div class="form message" style="display:none">
<div class="form__field-label">
<div class="form form--select message__select">
<div class="form__contain" style="display: none;">
<span class="form__field form__button">
<svg class="icon">
<use href="#icon-chevron"></use>
</svg>
</span>
</div>
</div>
<label for="ShippingCountry" class="message__label">
<span class="form__error">* </span>Country </label>
<label class="message__group" role="alert">
<span class="message__invalid"> Please choose a country. </span>
</label>
</div>
</div>
</div>
</div>
</fieldset>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="form__copy form__action-text">
<div class="form__action">
<button type="submit" id="AcceptOfferButton" name="acceptOffer" class="button" data-express-checkout-order-type="card">
<span class="order-btn">
<span>Process Order</span>
</span>
</button>
</div>
<p id="ProcessOrderDisclaimer" data-express-checkout-order-type="card">By clicking Process Order, your credit card will be charged the amount above. Click only once.</p>
<div class="form__ssl">
<img src="/shared/images/PositiveSSL_tl_trans.png" alt="Secure Site SSL Encryption" width="100" height="100" loading="lazy">
</div>
</div>
</div>
<span class="svg-symbols">
<svg>
<symbol id="icon-chevron" x="0px" y="0px" viewBox="0 0 25.228 14.029">
<g transform="translate(1.414 1.414)">
<path d="M0,11.2,11.2,0m0,22.4L0,11.2" transform="translate(0 11.2) rotate(-90)" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"></path>
</g>
</symbol>
</svg>
</span>
<input type="hidden" id="BillingCountry" name="BillingCountry" value="USA" placeholder="*Country"><input type="hidden" id="ShippingCountry" name="ShippingCountry" value="USA" placeholder="*Country">
</form>
Text Content
Skip To Main Content? Full Body Comfort and Support Full Body Comfort and Support Home Videos Features & Benefits Frequently Asked Questions Order Now 2 Payments of $29.99 2 Payments Of $ 29 99 FREE SHIPPING! $ 20 Value Free Bonus Laundry Care Bag Order Now Designed In USA THE BODY PILLOW THAT CRADLES YOU FROM HEAD TO TOE! UNIQUE ERGONOMIC DESIGN Promotes Proper Alignment and Pressure-Relieving Comfort Comfy Curves Hug Your Body In All The Right Places REJUVENATE WITH FULL LENGTH BODY SUPPORT 44” x 25” x 6” Enjoy Cozy & Supportive Softness Filled with Medium-Firm Premium Fibers to Ensure Comfort; 100% Hypo-allergenic NESTLE INTO THE SUPER-SOFT FABRIC Melt Away in the Luxurious Feel of the Premium Hypoallergenic, Washable Fabric Watch The Show How To Use Expert Review User Testimonials FEATURES & BENEFITS * Orthopedically Designed to Cradle and Support You from Head to Toe! * Helps Aligns Your Spine for The Best Night's Sleep of Your Life! * Supports Pressure Relief on Your Shoulder and Hips for A More Restful Sleep! * 100% Hypoallergenic Fabric to Keep You Cool All Night Long! * Fits Any Body Shape in Any Sleep Position with the Patented Design! * 100% Machine Washable in Bonus Laundry Care Bag! CONTOUR SWAN IS PERFECT FOR: Side Sleepers Back Sleepers Stomach Sleepers Pregnancy Click Here To Order Now HELPS ALIGN YOUR SPINE Enjoy a better night's sleep with the additional support and comfort of the Contour Swan. This pillow helps place your body in total correct alignment, so you wake up with less aches and pains and feel more rested each morning Before After Improved shoulder and hip comfort FULL BODY COMFORT & SUPPORT UNIQUE ERGONOMIC DESIGN Promotes Proper Alignment and Pressure-Relieving Comfort NESTLE INTO THE SUPER-SOFT FABRIC Melt Away in the Luxurious Feel of the Silky 100% Hypoallergenic Fabric REJUVENATE WITH FULL LENGTH BODY SUPPORT 44” x 25” x 6” COMFY CURVES Wraps Your Body In A Plush Cloud of Softness ENJOY COZY & SUPPORTIVE SOFTNESS Filled with Medium-Firm Premium Fibers to Ensure Comfort 100% WASHABLE Super Soft Fabric Stays Clean and Fresh Always PRESSURE-RELIEVING COMFORT BEFORE Ordinary Pillow AFTER Contour Swan THE MOST COMFORTABLE SLEEP OF YOUR LIFE. HERE'S WHY. SUPPORTS 3 PRIMARY ZONES The Swan Pillow was designed into 3 main zones that deliver incredible support and comfort for your whole body. * Head and Shoulders - designed extra wide to gently cradle your entire head and neck. * Torso - soft, huggable mid-section takes pressure off your arms and provides stability for your torso to lean into and hug. * Legs - bottom half has a tapered design that makes it the perfect leg pillow, helping to stabilize your hips to align your spine. REPLACES EVERY OTHER PILLOW Time to toss all your extra pillows. The Swan pillow cuddles you all night long to help reduce tossing and turning throughout the night. It molds to your body and places you in a complete oasis of comfort and support from your head to toe. EASY TO CLEAN The laundry care bag makes machine washing and drying a breeze. * Machine wash on gentle cycle * Tumble dry on low heat * Can also be used to store your pillow on a closet hanger/hook when not in use GET A BETTER NIGHT'S SLEEP The Swan body pillow was designed for comfort and support, to help you sleep more restfully and wake up feeling rejuvenated for years to come. Custom fit pillowcases are available after initial purchase to extend the life and cleanliness of your Contour Swan Pillow. 5 STAR REVIEWS > “This is a great body pillow for side sleepers. It is big enough to > accommodate larger/taller bodies, has a super soft exterior, and gives a great > night’s sleep. The SWAN’s shape is superior to regular rectangle body pillows > that aren’t designed with a person’s normal sleeping positions in mind. I’d > recommend this pillow to anybody trying to get a good night’s sleep better > than the traditional body pillow’s shape can provide.” - Mark L. > “This full body pillow is great! I like sleeping curled up but end up waking > with a terrible neck and lower back pain. The SWAN pillow keeps my body > aligned as it gives me something to hug and sleep. The fabric is sooo soft > that I can just sleep on it all day. I love the fact that it is wider where > you lay your head and it supports my neck too. This pillow really keeps me in > place and fits between my knees, also the extended area on the back cradles me > and makes me feel like I am wrapped in a cocoon.” - Sanya K. > “MUST BUY TWO!! I originally purchased the Swan Pillow because I have hip > troubles with a very old mattress. It is a dream come true with the instant > shoulder and hip relief. I can sleep soundly without tossing and turning. Its > a gentle hug throughout the night with full body support. My only problem with > the Swan pillow is that my husband stole it from me ?. Side sleeping has been > difficult for him after dealing with digestive issues, but the Swan pillow is > a game changer for all side sleepers. Back to buy my second pillow!” - Kayla R. > “Great pillow to have for surgery recovery. Sleeping on my back is painful but > this pillow allows me to sleep on my side without any pressure. Very > comfortable and supportive.” - Jon SIGNUP TO LEARN ABOUT NEW PRODUCTS AND SPECIAL OFFERS This Offer Is Not Available In Stores Fill out the form below or call 800-376-8720 to order your Contour Swan Pillow Now! STEP 1: CHOOSE YOUR PAYMENT PLAN Pay In Full Today Or Pay in 2 Easy Monthly Installments Please choose a payment plan STEP 2: CHOOSE YOUR PACKAGE TV Offer 1 Contour Swan Pillow 1 Free Laundry Care Bag FREE SHIPPING List Price: $80 $59.98 List Price: $80 $59.98 2 Payments of $29.99 25% off Most Popular 2 Contour Swan Pillows 2 Free Laundry Care Bags FREE SHIPPING List Price: $160 $99.96 Only $49.98 per pillow! List Price: $160 $99.96 / $49.98 per pillow 2 Payments of $49.98 37% off Best Value 4 Contour Swan Pillows 4 Free Laundry Care Bags FREE SHIPPING List Price: $320 $179.92 Only $44.98 per pillow! List Price: $320 $179.92 / $44.98 per pillow 2 Payments of $89.96 45% off STEP 3: OPTIONAL ADD-ONS Custom Fit Pillowcases $24.99 FREE SHIPPING * Qty 1 2 3 4 Please choose a quantity *Indicates required field STEP 4: REVIEW YOUR ORDER STEP 2: Review Your Order Description Quantity Price S&H MOST POPULAR - SWAN Body Pillow (set of 2)1$99.96$0.00 Sub Total: $99.96 State Tax: $0.00 Estimated Order Total $99.96 STEP 5: SELECT PAYMENT TYPE * Card Number Please enter a valid card number. 01 - Jan 02 - Feb 03 - Mar 04 - Apr 05 - May 06 - Jun 07 - Jul 08 - Aug 09 - Sep 10 - Oct 11 - Nov 12 - Dec *Expiration Date: Please choose an expiration month. 20222023202420252026202720282029203020312032 * Card Expiration Year Please enter an expiration year. * CVV2 Please enter a CVV number. What is CVV2? STEP 6: BILLING ADDRESS * First Name Please enter a first name. * Last Name Please enter a last name. * Address Please enter an address. Address 2 Example: Suite / Apt., etc. Please enter an address. * City Please enter a city. Alabama Arizona Arkansas California Colorado Connecticut Delaware District Of Columbia Florida Georgia Idaho Illinois Indiana Iowa Kansas Kentucky Louisiana Maine Maryland Massachusetts Michigan Minnesota Mississippi Missouri Montana Nebraska Nevada New Hampshire New Jersey New Mexico New York North Carolina North Dakota Ohio Oklahoma Oregon Pennsylvania Rhode Island South Carolina South Dakota Tennessee Texas Utah Vermont Virginia Washington West Virginia Wisconsin Wyoming * State Please choose a state. * Zip Code Please enter a zip code. * Country Please choose a country. * Phone Please enter a phone number. * Email Please enter an email address. Check if your shipping address is different than your billing address. STEP 7: SHIPPING ADDRESS * First Name Please enter a first name. * Last Name Please enter a last name. * Address Please enter an address. Address 2 Example: Street / Apt., etc. Please enter an address. * City Please enter a city. Alabama Arizona Arkansas California Colorado Connecticut Delaware District Of Columbia Florida Georgia Idaho Illinois Indiana Iowa Kansas Kentucky Louisiana Maine Maryland Massachusetts Michigan Minnesota Mississippi Missouri Montana Nebraska Nevada New Hampshire New Jersey New Mexico New York North Carolina North Dakota Ohio Oklahoma Oregon Pennsylvania Rhode Island South Carolina South Dakota Tennessee Texas Utah Vermont Virginia Washington West Virginia Wisconsin Wyoming * State Please choose a state. * Zip Code Please enter a zip code. * Country Please choose a country. Process Order By clicking Process Order, your credit card will be charged the amount above. Click only once. OFFER DETAILS: Order your Contour Swan Pillow for 2 easy payments of $29.99. You may also choose to make one convenient payment of $59.98. As an option, you may also choose from our 2-pack and 4-pack bundles. See order form for more details. All orders include FREE SHIPPING. State sales tax will be charged where applicable. For the 2-payment option, tax on the full product price will be included on today's payment. We're sorry, but this product cannot be shipped to a PO Box. 90-Day Money Back Comfort Guarantee: If for any reason you are not completely satisfied with your product, simply return it within 90 days for a full credit or refund (less any S&H). Please see Return Policy for full details. Home FAQ Customer Service Shipping Policy Return Policy Privacy Policy Security Policy Arbitration Agreement Terms and Conditions Site Map Order Now Web by: Digital Target Marketing THANK YOU FOR VISITING! WE JUST HAVE ONE QUESTION BEFORE YOU GO. WHAT IS YOUR MAIN REASON FOR NOT ORDERING TODAY? I’ll be back! I’m just not ready to order yet. Not sure if this is a good value. I want to buy it/see it at the store. I am not sure if this is the best body pillow for me. Other Submit