//=====================================================================
//
//  This script will combine a number of fields to create a single 
//  NAME field.  This NAME field will then be passed to 
//  function addToCart within the script saved in nopcart.js
//
//===================================================================== 

function FormatAddToCart(thisForm) {
   var saveName = thisForm.NAME.value;

	if ( thisForm.NVAR != null )   thisForm.NAME.value += thisForm.NVAR.value;
	if ( thisForm.NVAR01 != null ) thisForm.NAME.value += "; " + thisForm.NVAR01.value;
	if ( thisForm.NVAR02 != null ) thisForm.NAME.value += "; " + thisForm.NVAR02.value;
	if ( thisForm.NVAR03 != null ) thisForm.NAME.value += "; " + thisForm.NVAR03.value;
	if ( thisForm.NVAR04 != null ) thisForm.NAME.value += "; " + thisForm.NVAR04.value;
	if ( thisForm.NVAR05 != null ) thisForm.NAME.value += "; " + thisForm.NVAR05.value;
	if ( thisForm.NVAR06 != null ) thisForm.NAME.value += "; " + thisForm.NVAR06.value;
	if ( thisForm.NVAR07 != null ) thisForm.NAME.value += "; " + thisForm.NVAR07.value;

  AddToCart(thisForm);
  thisForm.NAME.value  = saveName;
}
//=====================================================================
//
//  This script will return an Item Number for a specific color
//
//===================================================================== 

function setItem(NVAR02) {
	if ( NVAR02 == "Pink" ) return("P-T5290");
	if ( NVAR02 == "Champaigne" ) return("P-T5291");
}

