Home › Toolset Professional Support › [Fixed in next Release] CSS classes applied to Form Messages field are not applied to error messages displayed in Forms validation
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.
This topic is split from https://toolset.com/forums/topic/how-to-check-for-a-custom-user-field-value-when-inputting-a-cpt-post-form/
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
---|---|---|---|---|---|---|
8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | - | - |
13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | - | - |
Supporter timezone: America/New_York (GMT-04:00)
Tagged: Content-submission forms, CRED API, Toolset Forms
Related documentation:
This topic contains 4 replies, has 2 voices.
Last updated by Christian Cox 3 years, 5 months ago.
Assisted by: Christian Cox.
One question I do have, is regarding the error message which now displays above my form. So on my post form code, I have the following shortcode in there:
[cred_field field='form_messages' class='uk-alert uk-alert-warning']
Notice I have slightly changed the css classes of the alert to 'uk-alert' etc (this is to use my theme framework styling, I am not using bootstrap but the uikit framework). However, the error message which displays is wrapped in the classes 'alert' and 'alert warning', so it reverts back to the bootstrap classes, even though I have overwritten those in my 'form_messages' shortcode.
Do you have any idea why that might be?
Hi, I'm not sure why CSS classes added to the Form Messages block or shortcode do not seem to be respected on the front-end Form validation message area. I'm able to see the same problem in a local test site, so I'm asking my 2nd tier team to take a closer look. I will let you know what I find out.
awesome - thank you Christian 🙂
My second tier team has confirmed the problem and escalated the issue to our developers. I will keep you posted here as I receive updates about the problem. In the meantime, I could help you determine a CSS selector you can use to override the styles applied to this area, if I can see it in the browser. Otherwise, you may need a custom JavaScript solution that swaps this error message container's CSS classes upon page load (for non-AJAX forms) or upon some global AJAX event (as there is no public API for Forms JavaScript events).
Quick update - our developers have informed me the fix for this issue will be included in the upcoming Forms 2.6.10 release. I still do not yet have a schedule available for the release, so I will continue to keep you up-to-date here as I receive more information.