adding functionality to checkout page