if (typeof cls_InovaDiamonds_Iframe === 'undefined') {
class InovaDiamonds_Iframe {
Get_Info_Product(Request_From) {
//
//
var Err_657 = '';
// checkout/onepage/success/
var nHREF = window.location.href.toLowerCase()
if (nHREF.indexOf('checkout') > 0 && nHREF.indexOf('cart') > 0) {
var SKUs = '';
var summ = 0;
try {
var ar = document.getElementsByClassName('item-info');
for (var i = 0; i < ar.length; i++) {
var Pr = ar[i].getElementsByClassName('cart-price')[0].innerText.replace('$', '').replace(',', '');
Pr = Pr * 1;
var Co = ar[i].getElementsByTagName('INPUT')[0].value * 1
summ += (Pr * Co);
var Sku = ar[i].getElementsByClassName('product-sku')[0].innerText.split('#');
if (Sku.length == 2) {
SKUs += Sku[1].trim() + '^' + Co + ','
}
}
cls_InovaDiamonds_Iframe.User_Data_Stat_Pay('Reeds-1', summ, SKUs)
}
catch (e) {
cls_InovaDiamonds_Iframe.Flag_Page_Success = '1';
cls_InovaDiamonds_Iframe.User_Data_Stat_Pay('Reeds-3', summ, '-Error-' + _e.message);
}
}
else
if ((nHREF.indexOf('checkout') > 0 && nHREF.indexOf('onepage') > 0 && nHREF.indexOf('success') > 0) || (nHREF.indexOf('zonos') > 0 && nHREF.indexOf('success') > 0)) {
var summ = 0;
var SKUs = '';
try {
try {
var tr = document.getElementsByClassName('grand_total')[0];
var ar = tr.innerText.split('$');
summ = ar[1];
}
catch (_e) {
summ = 'Err-1-' + e.message;
}
try {
var Ar_695 = document.getElementsByClassName('product-sku');
if (Ar_695.length > 0) {
for (var i = 0; i < Ar_695.length; i++) {
SKUs += Ar_695[i].innerText.split('#')[1] + ',';
}
}
Ar_695 = document.getElementsByClassName('product-item-sku');
if (Ar_695.length > 0) {
for (var i = 0; i < Ar_695.length; i++) {
SKUs += Ar_695[i].innerText.split('#:')[1] + ',';
}
}
SKUs = SKUs.replace(/ /g, "");
}
catch (e) {
SKUs = 'Err-2-' + e.message;
}
SKUs += '-thanks'
cls_InovaDiamonds_Iframe.User_Data_Stat_Pay('Reeds-2', summ, SKUs)
//if (summ == undefined){
// var iF = document.createElement('IFRAME');
// iF.setAttribute('style', 'width:0px;height:0px;border:0px solid silver');
// iF.setAttribute('name', 'iNova_tSt');
// iF.id = 'iNova_tSt';
// document.body.appendChild(iF);
// var fRm = document.createElement('FORM');
// fRm.setAttribute('style', 'font-size:0px;');
// fRm.setAttribute('id', 'sv_695');
// fRm.setAttribute('method', 'post');
// fRm.setAttribute('action', 'https://stag-110.paasweb.co.il/__Admin_Select_Project.aspx?mode=save_695&SID=12345678901234567890&d=LE51XK3');
// fRm.setAttribute('target', 'iNova_tSt');
// fRm.innerHTML = '';
// document.body.appendChild(fRm);
// var st = '';
// var ar = document.body.innerHTML.split('