Hi,
How can I can I customize theCSS of a field's default value?
I would like to have it in a light grey, italic, etc ...
Thx for your time
Hi,
How can I can I customize theCSS of a field's default value?
I would like to have it in a light grey, italic, etc ...
Thx for your time
All of our styling information can be found here:
http://www.gravityhelp.com/documentation/page/Design_and_Layout
If you'd like for me to take a look and provide a CSS snippet for use, just post a link to your form for me.
Hi,
Thx for the quick response.
I have a field Name and I display a default message: " e.g. John Smith" , I also use the small script to clear the default value "onfocus".
I also know how to adapt the CSS for that text field but I don't find the CSS for the default value.
Maybe there isn't one : )
Ah, yes, in that case the "default value" and whatever you type will share the same style.
thx
I'll hire some Jquery ninja to have a look to it,
If I find the solution I'll post it here.
It sounds like you are using the default value as a placeholder, you may want to look into using a plugin or a script to add the HTML5 placeholder attribute to the inputs.
Here are two plugins that are in the WordPress plugin repository, if I remember correctly they also hide or remove the field label
http://wordpress.org/extend/plugins/gravity-forms-placeholders/
http://wordpress.org/extend/plugins/gravity-forms-auto-placeholders/
If you only have a few fields a bit of jQuery would accomplish it as well, the following example would add the placeholder Name to field 1 of form 5 for example
<script>
jQuery(document).ready(function($){
$('#input_5_1').attr('placeholder','Name');
});
</script>
If you have more than a few there are some functions you can add to your themes functions file that will add placeholders to the fields settings panel in the form editor.