
function fillTurnaround(){ 
 // this function is used to fill the category list on load
addOption(document.drop_postcards.Turnaround, "Same Day", "Same Day", "");
addOption(document.drop_postcards.Turnaround, "2-3 Business Days", "2-3 Business Days", "");
}

function SelectPaper(){
// ON selection of category this function will work

removeAllOptions(document.drop_postcards.Paper);

if(document.drop_postcards.Turnaround.value == 'Same Day'){
addOption(document.drop_postcards.Paper,"", "--Select Paper--");
addOption(document.drop_postcards.Paper,"Regular Paper - Same Day", "Regular Paper");
addOption(document.drop_postcards.Paper,"Premium Paper - Same Day", "Premium Paper");
}
if(document.drop_postcards.Turnaround.value == '2-3 Business Days'){
addOption(document.drop_postcards.Paper,"", "--Select Paper--");
addOption(document.drop_postcards.Paper,"Regular Paper - 2 to 3 Days", "Regular Paper");
addOption(document.drop_postcards.Paper,"Premium Paper - 2 to 3 Days", "Premium Paper");
}

}

function SelectColor(){
// ON selection of category this function will work

removeAllOptions(document.drop_postcards.Color);

// Color

if(document.drop_postcards.Paper.value == 'Regular Paper - Same Day'){
addOption(document.drop_postcards.Color, "", "--Select Color--");
addOption(document.drop_postcards.Color,"Full color front / Nothing on back (4/0) - Regular - Same Day", "Full color front / Nothing on back (4/0)");
addOption(document.drop_postcards.Color,"Full color front / Full color back (4/4) - Regular - Same Day", "Full color front / Full color back (4/4)");
addOption(document.drop_postcards.Color,"Full color front / one color black (4/1) - Regular - Same Day", "Full color front / one color black (4/1)");
addOption(document.drop_postcards.Color,"One color black / Nothing on back (1/0) - Regular - Same Day", "One color black / Nothing on back (1/0)");
addOption(document.drop_postcards.Color,"One color black / one color black (1/1) - Regular - Same Day", "One color black / one color black (1/1)");
}
if(document.drop_postcards.Paper.value == 'Premium Paper - Same Day'){
addOption(document.drop_postcards.Color, "", "--Select Color--");
addOption(document.drop_postcards.Color,"Full color front / Nothing on back (4/0) - Premium - Same Day", "Full color front / Nothing on back (4/0)");
addOption(document.drop_postcards.Color,"Full color front / Full color back (4/4) - Premium - Same Day", "Full color front / Full color back (4/4)");
addOption(document.drop_postcards.Color,"Full color front / one color black (4/1) - Premium - Same Day", "Full color front / one color black (4/1)");
addOption(document.drop_postcards.Color,"One color black / Nothing on back (1/0) - Premium - Same Day", "One color black / Nothing on back (1/0)");
addOption(document.drop_postcards.Color,"One color black / one color black (1/1) - Premium - Same Day", "One color black / one color black (1/1)");
}
if(document.drop_postcards.Paper.value == 'Regular Paper - 2 to 3 Days'){
addOption(document.drop_postcards.Color, "", "--Select Color--");
addOption(document.drop_postcards.Color,"Full color front / Nothing on back (4/0) - Regular - Two to Three", "Full color front / Nothing on back (4/0)");
addOption(document.drop_postcards.Color,"Full color front / Full color back (4/4) - Regular - Two to Three", "Full color front / Full color back (4/4)");
addOption(document.drop_postcards.Color,"Full color front / one color black (4/1) - Regular - Two to Three", "Full color front / one color black (4/1)", "");
addOption(document.drop_postcards.Color,"One color black / Nothing on back (1/0) - Regular - Two to Three", "One color black / Nothing on back (1/0)", "");
addOption(document.drop_postcards.Color,"One color black / one color black (1/1) - Regular - Two to Three", "One color black / one color black (1/1)", "");
}
if(document.drop_postcards.Paper.value == 'Premium Paper - 2 to 3 Days'){
addOption(document.drop_postcards.Color, "", "--Select Color--");
addOption(document.drop_postcards.Color,"Full color front / Nothing on back (4/0) - Premium - Two to Three", "Full color front / Nothing on back (4/0)");
addOption(document.drop_postcards.Color,"Full color front / Full color back (4/4) - Premium - Two to Three", "Full color front / Full color back (4/4)");
addOption(document.drop_postcards.Color,"Full color front / one color black (4/1) - Premium - Two to Three", "Full color front / one color black (4/1)");
addOption(document.drop_postcards.Color,"One color black / Nothing on back (1/0) - Premium - Two to Three", "One color black / Nothing on back (1/0)");
addOption(document.drop_postcards.Color,"One color black / one color black (1/1) - Premium - Two to Three", "One color black / one color black (1/1)");
}

}


function SelectQuantity(){
// ON selection of category this function will work

removeAllOptions(document.drop_postcards.Quantity);

// Quantity - Regular Paper - Same Day

if(document.drop_postcards.Color.value == 'Full color front / Nothing on back (4/0) - Regular - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50 - $40.00", "50 - $40.00");
addOption(document.drop_postcards.Quantity,"100 - $45.00", "100 - $45.00");
addOption(document.drop_postcards.Quantity,"250 - $55.00", "250 - $55.00");
addOption(document.drop_postcards.Quantity,"500 - $65.00", "500 - $65.00");
}
if(document.drop_postcards.Color.value == 'Full color front / Full color back (4/4) - Regular - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50 - $42.50", "50 - $42.50");
addOption(document.drop_postcards.Quantity,"100 - $47.50", "100 - $47.50");
addOption(document.drop_postcards.Quantity,"250 - $60.00", "250 - $60.00");
addOption(document.drop_postcards.Quantity,"500", "500");
}
if(document.drop_postcards.Color.value == 'Full color front / one color black (4/1) - Regular - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
}
if(document.drop_postcards.Color.value == 'One color black / Nothing on back (1/0) - Regular - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
}
if(document.drop_postcards.Color.value == 'One color black / one color black (1/1) - Regular - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
}

// Quantity - Premium Paper - Same Day

if(document.drop_postcards.Color.value == 'Full color front / Nothing on back (4/0) - Premium - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100 ");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
}
if(document.drop_postcards.Color.value == 'Full color front / Full color back (4/4) - Premium - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
}
if(document.drop_postcards.Color.value == 'Full color front / one color black (4/1) - Premium - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
}
if(document.drop_postcards.Color.value == 'One color black / Nothing on back (1/0) - Premium - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
}
if(document.drop_postcards.Color.value == 'One color black / one color black (1/1) - Premium - Same Day'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
}

// Quantity - Regular Paper - Two to Three Days

if(document.drop_postcards.Color.value == 'Full color front / Nothing on back (4/0) - Regular - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50 - $30.00", "50 - $30.00");
addOption(document.drop_postcards.Quantity,"100 - $35.00", "100 - $35.00");
addOption(document.drop_postcards.Quantity,"250 - $40.00", "250 - $40.00");
addOption(document.drop_postcards.Quantity,"500 - $55.00", "500 - $55.00");
addOption(document.drop_postcards.Quantity,"1000 - $68.50", "1000 - $68.50");
}
if(document.drop_postcards.Color.value == 'Full color front / Full color back (4/4) - Regular - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50 - $40.00", "50 - $40.00");
addOption(document.drop_postcards.Quantity,"100 - $45.00", "100 - $45.00");
addOption(document.drop_postcards.Quantity,"250 - $50.00", "250 - $50.00");
addOption(document.drop_postcards.Quantity,"500 - $65.00", "500 - $65.00");
addOption(document.drop_postcards.Quantity,"1000 - $75.00", "1000 - $75.00");
}
if(document.drop_postcards.Color.value == 'Full color front / one color black (4/1) - Regular - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
addOption(document.drop_postcards.Quantity,"1000", "1000");
}
if(document.drop_postcards.Color.value == 'One color black / Nothing on back (1/0) - Regular - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
addOption(document.drop_postcards.Quantity,"1000", "1000");
}
if(document.drop_postcards.Color.value == 'One color black / one color black (1/1) - Regular - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
addOption(document.drop_postcards.Quantity,"1000", "1000");
}

// Quantity - Premium Paper - Two to Three Days

if(document.drop_postcards.Color.value == 'Full color front / Nothing on back (4/0) - Premium - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50 - $30.00", "50 - $30.00");
addOption(document.drop_postcards.Quantity,"100 - $35.00", "100 - $35.00");
addOption(document.drop_postcards.Quantity,"250 - $40.00", "250 - $40.00");
addOption(document.drop_postcards.Quantity,"500 - $55.00", "500 - $55.00");
addOption(document.drop_postcards.Quantity,"1000 - $68.50", "1000 - $68.50");
}
if(document.drop_postcards.Color.value == 'Full color front / Full color back (4/4) - Premium - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50 - $40.00", "50 - $40.00");
addOption(document.drop_postcards.Quantity,"100 - $45.00", "100 - $45.00");
addOption(document.drop_postcards.Quantity,"250 - $50.00", "250 - $50.00");
addOption(document.drop_postcards.Quantity,"500 - $65.00", "500 - $65.00");
addOption(document.drop_postcards.Quantity,"1000 - $75.00", "1000 - $75.00");
}
if(document.drop_postcards.Color.value == 'Full color front / one color black (4/1) - Premium - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
addOption(document.drop_postcards.Quantity,"1000", "1000");
}
if(document.drop_postcards.Color.value == 'One color black / Nothing on back (1/0) - Premium - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
addOption(document.drop_postcards.Quantity,"1000", "1000");
}
if(document.drop_postcards.Color.value == 'One color black / one color black (1/1) - Premium - Two to Three'){
addOption(document.drop_postcards.Quantity, "", "--Select Quantity--");
addOption(document.drop_postcards.Quantity,"50", "50");
addOption(document.drop_postcards.Quantity,"100", "100");
addOption(document.drop_postcards.Quantity,"250", "250");
addOption(document.drop_postcards.Quantity,"500", "500");
addOption(document.drop_postcards.Quantity,"1000", "1000");
}

}

////////////////// 

function removeAllOptions(selectbox)
{
	var i;
	for(i=selectbox.options.length-1;i>=0;i--)
	{
		//selectbox.options.remove(i);
		selectbox.remove(i);
	}
}


function addOption(selectbox, value, text )
{
	var optn = document.createElement("OPTION");
	optn.text = text;
	optn.value = value;

	selectbox.options.add(optn);
}
