var _g_eceDefCookieName = "_eceCartv2_" + "12583";
var _g_eceDefCookieMax = 5;
var _g_eceDefCookieSizeMax = 4000;
var _g_eceDefExpDate = new Date();
_g_eceDefExpDate.setTime(new Date().getTime() + (2 * 24 * 60 * 60 * 1000));
function _eceGetSubDomain()
{
if (document.getElementById && location && location.hostname)
{
var _eceUseDomain = location.hostname.toLowerCase();
var _eceUseDomainArray = _eceUseDomain.split(".");
if (_eceUseDomainArray.length >= 2)
{
if (_eceUseDomainArray[_eceUseDomainArray.length - 1].length >= 2)
{
if (isNaN(_eceUseDomainArray[_eceUseDomainArray.length - 1]))
{
var _eceTmpDomainStr = _eceUseDomainArray[_eceUseDomainArray.length - 2] + "." + _eceUseDomainArray[_eceUseDomainArray.length - 1];
if ((_eceUseDomainArray[_eceUseDomainArray.length - 2].length <= 2 || _eceUseDomainArray[_eceUseDomainArray.length - 2] == "com") && _eceUseDomainArray.length > 2)
_eceTmpDomainStr = _eceUseDomainArray[_eceUseDomainArray.length - 3] + "." + _eceTmpDomainStr;
return ("; domain=." + _eceTmpDomainStr);
//return ("; domain=." + _eceUseDomainArray[_eceUseDomainArray.length - 2] + "." + _eceUseDomainArray[_eceUseDomainArray.length - 1]);
}
}
}
}
return "";
}
function _eceGetCookie (cookieName)
{
var retStr = "";
if (document.cookie)
{
if (!cookieName)
cookieName = _g_eceDefCookieName;
var cookieArray = document.cookie.split(";")
var nCount = 0;
for (var n = 0; n < cookieArray.length; n++)
{
while(cookieArray[n].charAt(0) == ' '){cookieArray[n] = cookieArray[n].substring(1)}
if (cookieArray[n].indexOf(cookieName) == 0)
{
retStr += cookieArray[n].substring(cookieName.length+1 + (nCount > 0 ? 1 : 0));
nCount++;
}
}
}
return retStr;
}
function _eceWriteCookie (cookieValue, cookieName)
{
if (cookieValue.length > (_g_eceDefCookieMax * _g_eceDefCookieSizeMax))
{
alert("Maximum cart size exceeded.");
return "";
}
if (!cookieName)
cookieName = _g_eceDefCookieName;
_eceResetCart(cookieName);
for (var n = 0; n < _g_eceDefCookieMax; n++)
{
if ( cookieValue.length > _g_eceDefCookieSizeMax)
{
var setCookie = cookieName + (n > 0 ? n : "") + "=" + cookieValue.substring(0, _g_eceDefCookieSizeMax);
document.cookie = setCookie + "; expires=" + _g_eceDefExpDate.toGMTString() + "; path=/" + _eceGetSubDomain();
cookieValue = cookieValue.substring(_g_eceDefCookieSizeMax);
}
else
{
var setCookie = cookieName + (n > 0 ? n : "") + "=" + cookieValue;
document.cookie = setCookie + "; expires=" + _g_eceDefExpDate.toGMTString() + "; path=/" + _eceGetSubDomain();
break;
}
}
return "";
}
function _eceResetCart(cookieName)
{
if (!cookieName)
cookieName = _g_eceDefCookieName;
var cookieArray = document.cookie.split(";")
for (var n = 0; n < cookieArray.length; n++)
{
while(cookieArray[n].charAt(0) == ' '){cookieArray[n] = cookieArray[n].substring(1)}
for (var x = 0; x < _g_eceDefCookieMax; x++)
{
var useCookiename = cookieName + (x > 0 ? x : "") + "=";
if (cookieArray[n].indexOf(useCookiename) == 0)
document.cookie = useCookiename + "" + "; expires=-1; path=/" + _eceGetSubDomain();
}
}
}
var _g_eceDefCartButton = "https://services.mercantec.com/images/sample_add.jpg";
var _g_eceMerchantID = "12583";
var _g_eceCartButton = "";
var _g_ecePostAddLink = "http://basketandfloral.com/Shopping_cart.htm";
var _g_eceDefQtyText = "Quantity:";
var _g_eceImgAltText = 'alt="' + "Add To Cart" + '"';
var _g_eceQtyText = "";
if (!_g_eceQtyText)
_g_eceQtyText = _g_eceDefQtyText;
if (_g_eceCartButton)
_g_eceImgAltText = "";
else
_g_eceCartButton = _g_eceDefCartButton;
function _eceAttributeOptionsStructure(ID, name, priceUnit, price, displayOrder, selected)
{
this.ID = ID;
this.name = name;
this.priceUnit = priceUnit;
this.price = price;
this.displayOrder = displayOrder;
this.selected = selected;
}
function _eceAttributeStructure(name, type, displayOrder, options)
{
this.name = name;
this.type = type;
this.displayOrder = displayOrder;
this.options = options
}
function _eceProductStructure(ID, name, description, price, shipping, attributesString, attributes)
{
this.ID = ID;
this.name = name;
this.description = description;
this.price = price;
this.shipping = shipping;
this.attributesString = attributesString;
this.attributes = attributes;
}
function _eceAttributeInputStructure(ID, input)
{
this.ID = ID;
this.input = input;
}
var _g_eceProductArray = new Array();
_g_eceProductArray[0] = new _eceProductStructure("139413", "Birthday Munchies", "Favorites for all. Oreo’s, chips, Snickers, cookies, chocolates, a mylar balloon and more.
", "$0.00", "$0.00", '