Modifying code and adding thankyou template