Skip Navigation

[Resolved] 'cred_generic_field' class attribute not wokring for select type fields

This support ticket is created 8 years, 4 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Tagged: 

This topic contains 1 reply, has 1 voice.

Last updated by margaritR 8 years, 4 months ago.

Author
Posts
#368086

Hi,

I just want to report a problem or a bug, is it?...

When I use the "Add Generic Field' and insert a field of type="select" the class attribute is not working.
It is creating the select element and all, but the class defined is not included.
It works just fine with textfield (that's the only one I've tried, since I need select now, so I didn't bother checking other types).

Here is an example of what I'm trying:

[cred_generic_field field="awesome_field" type="select" class="nice_class_name_but_not_working" urlparam=""]
{
"required":1,
"validate_format":0,
"persist":0,
"default":[],
"options":[
{"value":"22","label":"11"}
]
}
[/cred_generic_field]

And here is the code rendered:

<select id="cred_form_5958_1-select-1-1455804801"  data-wpt-validate="{"required":{"args":{"1":true},"message":"Това поле е задължително"}}" data-wpt-field-title="awesome_field" class="wpt-form-select form-select select" data-wpt-type="select" name="awesome_field">
<option value="22" class="wpt-form-option form-option option" data-wpt-type="option" data-wpt-id="cred_form_5958_1_cred_form_5958_1-select-1-1455804801" data-wpt-name="awesome_field">11</option>
</select>
#368149

Ok, I have just updated the plug-in to the latest version and is working now.

Regards,
Jordan

This ticket is now closed. If you're a Toolset client and need related help, please open a new support ticket.