Page 1 of 1

Agree to terms checkbox

Posted: Sat Mar 14, 2020 9:42 am
by piotrh
Hello Pablo,
How to add "agree to terms" checkbox to form? Only by agreeing to terms someone should be able to submit message.
Bests
P

Re: Agree to terms checkbox

Posted: Sat Mar 14, 2020 12:34 pm
by Pablo
You can use conditions to implement this:
http://www.wysiwygwebbuilder.com/conditions.html

Re: Agree to terms checkbox

Posted: Sun Mar 15, 2020 7:42 pm
by piotrh
Thank You,
I followed instructions and it works,
but succes/error dialog stopped to show up after cliking submit button...
I have no what did I screwd up...
P
Here is wwb file with what I've done:
/link removed/

Re: Agree to terms checkbox

Posted: Sun Mar 15, 2020 9:07 pm
by Pablo
I cannot open your project.
Can you please remove all extensions and other non relevant content?

Re: Agree to terms checkbox

Posted: Sun Mar 15, 2020 9:52 pm
by piotrh
There was no other than official extensions there,
but I removed all what is not part of form.
You can download now, I've re-upladed file.
P

Re: Agree to terms checkbox

Posted: Mon Mar 16, 2020 7:40 am
by Pablo
In 'Editbox3' there is an error in your validation settings.
If you set a minimum then the maximum value cannot be empty.

Re: Agree to terms checkbox

Posted: Mon Mar 16, 2020 10:18 am
by piotrh
Pablo,
When I added maximum value - error/succes is still not showing up. But when I removed minimum and maximum value, its working.
I still dont know how to configure this object to work and correctly validate the phone number.

I also have 2 more questuions:
How to make form empty after sucessfully sending a message? Now all fields are still ocuppied with data, after message was send.
How to make submit button gray while being disabled and turn to different color after checkbox has been checked?

P

Re: Agree to terms checkbox

Posted: Mon Mar 16, 2020 11:08 am
by Pablo
To make this work, please make sure you enter values that make sense.
When you set a minimum you will also have to set a maximum.
Also, in 'Numeric format' you did not enter any values.
How to make form empty after successfully sending a message?
This require a custom script.
How to make submit button gray while being disabled
You can use pseudo classes to implement styles for different states.
http://wysiwygwebbuilder.com/pseudoclasses.html

:disabled can be used disabled objects.
:checked can be used for checked objects.

More info:
https://www.w3schools.com/css/css_pseudo_classes.asp

Re: Agree to terms checkbox

Posted: Mon Mar 16, 2020 1:33 pm
by piotrh
Thank You, I'll try to dig deeper into it.
This require a custom script.
Would be nice if WWB had option to do that :)

If the form stays ocuppied with data, does it mean that site uses cookies already?

P

Re: Agree to terms checkbox

Posted: Mon Mar 16, 2020 1:35 pm
by Pablo
If the form stays ocuppied with data, does it mean that site uses cookies already?
Or the browser is configured to use 'auto complete'