Can Gravity for, do this?
Also, if it can, does it affect required validation. I wouldn't want the initial text to qualify as meeting a required field
Can Gravity for, do this?
Also, if it can, does it affect required validation. I wouldn't want the initial text to qualify as meeting a required field
What you are describing is referred to as placeholder functionality. It's text that appears inside an input and then when the user clicks on the field, it goes away. Currently this is not a built in feature of Gravity Forms, but it can be done as a simple customization.
Here is information on how this can be done:
http://www.gravityhelp.com/clearing-default-form-field-values-with-jquery/
We do plan on implementing placeholder functionality as a native feature in the future. We were trying to hold out until HTML5 gained more acceptance so it could be implemented without requiring Javascript as HTML5 supports the placeholder attribute as a built in feature, but HTML5 adoption has been slow.
So we are planning on implementing it as both HTML5 and a fallback to using Javascript sometime in the near year.
Here is an alterate method that uses the labels as placeholders and works with ajax validation:
http://www.gravityhelp.com/forums/topic/heres-how-to-add-placeholder-functionality-which-works-with-ajax-validation
Thanks for the code, @minicast.