added logic to forms