wpDiscuz - WordPress Comment Plugin
Request: add custom...
 
Share:
Notifications
Clear all

Request: add custom class input field for all fields when using the form editor


AdamTheForumUser
Posts: 54
Topic starter
(@adamtheforumuser)
Trusted Member
Joined: 9 months ago

This would be really useful so that an install can quickly inherit the styles of a theme's general CSS.

4 Replies
Asti
Posts: 3852
 Asti
Support
(@asti)
Support member
Joined: 4 years ago

@adamtheforumuser,

Don't follow you well. Each filed created by you has it's own class and ID. See the example shown in the screenshot: 

image
Reply
AdamTheForumUser
Posts: 54
Topic starter
(@adamtheforumuser)
Trusted Member
Joined: 9 months ago

What I was requesting was that in the form creation, you can define a css class.   Then that CSS class would be added to the class attribute on the field when it is rendered.

This would have the advantage that you can use existing css classes and make zero changes to your css.

For example, you have a class existing in your website called .btn that does lots of styling to buttons.   In the form creation interface you'd then add "btn" as a custom class and as if by magic with no site code changes required the buttons on the form would then inherit the standard button style. 

 

Reply
1 Reply
Asti
 Asti
Support
(@asti)
Joined: 4 years ago

Support member
Posts: 3852

You can do it using jQuery .addClass() function. 

Reply
AdamTheForumUser
Posts: 54
Topic starter
(@adamtheforumuser)
Trusted Member
Joined: 9 months ago

Yes sure.  It was just a request to have this in your interface for someone that doesnt want to/know how to do it in code.   Ie someone that literally wants to just install the plugin and get it setup using existing CSS classes very quickly with no coding required.

Reply
Share: