');
itemlist = 0;
for (var i = 0; i <= fulllist.length; i++) {
if (fulllist.substring(i,i+1) == '[') {
thisitem = 1;
itemstart = i+1;
} else if (fulllist.substring(i,i+1) == ']') {
itemend = i;
thequantity = fulllist.substring(itemstart, itemend);
itemtotal = 0;
itemtotal = (eval(theprice*thequantity));
//cpr
itemtotal_cpr = 0;
//-----------------------------------------------------------------------------------
// this determines if each item is a newsletter or a cpr
if (thenumber != "AS"){
if (thenumber != "OE"){
if (thenumber != "CB"){
if (thenumber != "CA"){
if (thenumber != "TM"){
if (thenumber != "TL"){
if (thenumber != "LS"){
if (thenumber != "ME"){
if (thenumber != "FR"){
cpr = "yes";
} else cpr = "no"
} else cpr = "no"
} else cpr = "no"
} else cpr = "no"
} else cpr = "no"
} else cpr = "no"
} else cpr = "no"
} else cpr = "no"
} else cpr = "no"
//end shipping test
// start cpr only tax test
if (cpr != "no"){
itemtotal_cpr = (eval(theprice*thequantity));
}
//----------------------------------------------------------------------------------------------
temptotal = itemtotal * 100;
subtotal = subtotal + itemtotal;
//cpr----------
subtotal_cpr = subtotal_cpr + itemtotal_cpr;
//-------------
weighttotal = 0;
weighttotal = (eval(theweight*thequantity));
subweight = subweight + weighttotal;
itemlist=itemlist+1;
document.write('
'+thequantity+'
');
document.writeln('
'+thenumber+'
'+theitem+'
'+theprice+'
'+alterError(itemtotal)+'
');
document.writeln('');
//if item is not a newsletter then set shipping to yes --this is prob the l o n g w a y, but then again ive never written alot of javascript so im happy if it works for now.
//probably can get rid of this inplace of above.. so this later
if (thenumber == "AS"){
shippingCharge = "no";
} else if (thenumber == "OE"){
shippingCharge = "no";
} else if (thenumber == "CB"){
shippingCharge = "no";
} else if (thenumber == "CB"){
shippingCharge = "no";
} else {
shippingCharge = "yes";
}