Just want to make sure I'm doing this right. If I wanted to target a label for a field, is this the best way to get it done:
body #gform_wrapper_1 label.gfield_label {
color: #ffffff;
}
TIA
Biagio
Just want to make sure I'm doing this right. If I wanted to target a label for a field, is this the best way to get it done:
body #gform_wrapper_1 label.gfield_label {
color: #ffffff;
}
TIA
Biagio
That will target all of the labels with the class "gfield_label" for form ID#1. If that's what you want to do, then you're golden.
If you only want to target one specific label, it would be like this
body #gform_wrapper_1 li#field_1_1 label.gfield_label {color:#fff}
that only applies the rule to the label that's contained in the "field_1_1" list item. Of course, you would replace the "field_1_1" with the actual ID from your form.
Thanks so much...I almost have it. My only question I still have is about
li#field_1_1
Where exactly am I looking to know that it's 1_1 ... is that because if there was another field it woudl be 1_2, since it would be the second 1 on the page? And I assume the first "1" indicates the form number?
Thanks so much!
The best way to find it is to simply view the source and get the ID from the parent <li > element.
Yes, the first number is the form ID# and the second is the field ID. The ID's are added when you add them to the editor, but if you re-arrange the order in the editor, the ID's won't be in sequential order in the form output. It's always best to give a quick look and make sure you have the correct ID - saves a lot of headaches.