Hi, I am using doc2form which is working well. The only problem I have and cannot seem to figure out is the following and would really appreciate help with it if anyone has any ideas...
My client has asked that there are 2 field inputs:-
1. email address
2. confirm email address
The idea is that the value of (1) and (2) need to match in order for the form to submit, otherwise a message pops up saying they don't match and please try again...
Ordinarily I suppose this would be easy on a flat page, just put in the appropriate JS and do an onsubmit in the form tag, however I am not sure where it is I need to be putting the JS or even if this is the right approach with doc2form.
I have tried to talk the client out of it, but alas they are adament they want both fields. So bang goes the easy route.
At present, D2F does not support this, as umbraco does not support this in the editor. You can create a custom data type that would allow for the compare validator.
You may also try adding the compare validator into the code of D2F. The code should be in app_code if you used the v4 version of D2F.
Thanks for the reply - I'm very new to Umbraco and so only slowly finding my way around it (big learning curve, short deadline - great!). Any cues on how to go about implementing your first suggestion of a custom data type allowing for the compare validator?
doc2form - matching field values
Hi, I am using doc2form which is working well. The only problem I have and cannot seem to figure out is the following and would really appreciate help with it if anyone has any ideas...
My client has asked that there are 2 field inputs:-
1. email address
2. confirm email address
The idea is that the value of (1) and (2) need to match in order for the form to submit, otherwise a message pops up saying they don't match and please try again...
Ordinarily I suppose this would be easy on a flat page, just put in the appropriate JS and do an onsubmit in the form tag, however I am not sure where it is I need to be putting the JS or even if this is the right approach with doc2form.
I have tried to talk the client out of it, but alas they are adament they want both fields. So bang goes the easy route.
If anyone has a suggestion please do let me know!
Abi
Hi Abi,
At present, D2F does not support this, as umbraco does not support this in the editor. You can create a custom data type that would allow for the compare validator.
You may also try adding the compare validator into the code of D2F. The code should be in app_code if you used the v4 version of D2F.
Case
Hi Case,
Thanks for the reply - I'm very new to Umbraco and so only slowly finding my way around it (big learning curve, short deadline - great!). Any cues on how to go about implementing your first suggestion of a custom data type allowing for the compare validator?
Sorry if I'm missing the obvious...
Abi
is working on a reply...