// THE FOLLOWING JAVASCRIPT PLACES THE PRODUCT COST AND AVAILABILITY INFO IN THE TOP CENTRE OF THE PAGE.

var dw='';


<!-- comment -->


dw+='<p CLASS="productCode">[Product Code: '+prod[p][0]+']</p>';

if(prod[p][5]!="") { /// provided for freebies that come with other tricks e.g Dimishing returns

dw+='<p class="productPrice">£'+prod[p][5];
if(prod[p][4]!="") {
	var diff=(prod[p][4]-prod[p][5]);
	dw+='<br /><SPAN CLASS="productPriceOld">RRP: <S>£'+prod[p][4]+'</S> - You save £'+diff.toFixed(2)+' ('+Math.ceil(100*diff/prod[p][4])+'%)<br />';
	}
dw+='</p>';
}



var what='<br /><a href="../../info/postage_delivery.html#avail">[what does this mean?]</a>';

if (prod[p][6]=="a") {var stock="Currently Out of Stock"+what; }
else if (prod[p][6]=="o") { var stock="Order On Demand"+what; }
else if (prod[p][6]=="d") { var stock="Product Discontinued"+what; }
else if (prod[p][6]=="p") { var stock="PRE-ORDER"+what; }
else { var stock="In Stock"; }

dw+='<p style="margin-left: 0px">Availability: '+stock+'</p>';




if (prod[p][9]!="") { 
dw+='<a href="#vidDem"><img src="../../graphics/icons/video_demo.gif" style="margin-left: 0px; border: 0px"/></a>';
}


//// ADDS CATEGORY LINKS ////
if(prod[p][16]!="") {
var c2=x; var c3=x;
for (i=0;i<catg.length;i++) {
	if (catg[i][0]==prod[p][16]) { var c1=i; } 
	if (catg[i][0]==prod[p][17]) { var c2=i; }
	if (catg[i][0]==prod[p][18]) { var c3=i; }
}
dw+='<p style="margin-left: 0px">Find in: <a href="../'+catg[c1][2]+'.html">'+catg[c1][1]+'</a>';
	if (c2!=x) { dw+='\, <a href="../'+catg[c2][2]+'.html">'+catg[c2][1]+'</a>'; }
	if (c3!=x) { dw+='\, <a href="../'+catg[c3][2]+'.html">'+catg[c3][1]+'</a>'; }
}


document.write(dw);

