Added form functionality