/*
To add a new Coupon Code Variable
add a new var line like this:

var coup1="CODE";

making sure the number or new coupon code aren't already in use
*/

var coup1="PRINTS1";
var coup2="PRINTS2";
var coup3="prints2";
var coup4="mom20";
var coup5="MOM20";

function CalculateOrder(form) {
/*
After adding a new coupon variable above, you need to add a new if 
statement so the program knows how to process your new coupon. 
Copy the following text (starting with if and ending with the }:

 if (form.text1.value == coup1)
 {
 form.discount_rate.value = "$";
 form.discount_rate2.value = "$";
 form.on0.value = "Coupon";
 form.os0.value = "CODE - Discount #%";
 }

Paste the text after the very last if statement but BEFORE the very last } on the page.
REPLACE # with the number you used above for the new variable (whatever number is next to coup in the var line
REPLACE ANY $ signs with the percentage off value you want your coupon to give.
REPLACE the word CODE in the last line (before the } ) with your new coupon code.


*/
 if (form.text1.value == coup1)
 {
 form.discount_rate.value = "10";
 form.discount_rate2.value = "10";
 form.on0.value = "Coupon";
 form.os0.value = "PRINTS1 - Discount 10%";
 }
  if (form.text1.value == coup2)
 {
 form.discount_rate.value = "15";
 form.discount_rate2.value = "15";
 form.on0.value = "Coupon";
 form.os0.value = "PRINTS2 - Discount 15%";
 }
  if (form.text1.value == coup3)
 {
 form.discount_rate.value = "15";
 form.discount_rate2.value = "15";
 form.on0.value = "Coupon";
 form.os0.value = "prints2 - Discount 15%";
 }
  if (form.text1.value == coup4)
 {
 form.discount_rate.value = "20";
 form.discount_rate2.value = "20";
 form.on0.value = "Coupon";
 form.os0.value = "Mother's Day Discount - Discount 20%";
 }  if (form.text1.value == coup5)
 {
 form.discount_rate.value = "20";
 form.discount_rate2.value = "20";
 form.on0.value = "Coupon";
 form.os0.value = "Mother's Day Discount - Discount 20%";
 }
 /*
 TO DELETE A COUPON CODE - DELETE the cooresponding VAR line and IF statement (delete everything from if to the }  )
 TO REPLACE A COUPON CODE with a new one, just change the variables (VAR value in the var line and the last line of the if statement )
 
 Finally - do not delete the last '}' from the file (below).
 */
 
}


