add confirmation email and add analytic code