• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Is it possible to highlight invalid fields?

Is it possible to highlight invalid fields? 14 years 6 months ago #11780

  • daajestaa
  • daajestaa's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 15
  • Thank you received: 3
Hi,

By default, when a user enters an invalid value, RSForms displays a user defined message above the field. This causes the overall size of the form to increase and push down the page as it must expand to accommodate the display of these messages. This is a problem for me as I have a form that must be constrained in size due to the page layout that surrounds it. I can of course remove the validation messages however I still want to be able to highlight to the user which values have been entered incorrectly as it's a large form.

What I would like to do is either draw the user's attention to the incorrect entry by highlighting the field with a red border or alternatively, changing the field's caption to red. Is this possible? If so, I'd be very grateful if someone could post how I might go about it. I'm ok with CSS but creating the back-end logic necessary to make it happen is well beyond me I'm afraid!

Many thanks....
Last Edit: 14 years 6 months ago by daajestaa. Reason: typo
The administrator has disabled public write access.

Re:Is it possible to highlight invalid fields? 14 years 6 months ago #11829

  • daajestaa
  • daajestaa's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 15
  • Thank you received: 3
I still have a BIG need to be able to do this. Does anyone know how and if so, could you please post an overview of what I would need to do to achieve this.

Many thanks...
The administrator has disabled public write access.

Re:Is it possible to highlight invalid fields? 14 years 5 months ago #11931

Hi,

I have the same problem with forms being pushed down after validation. I believe the developers should really consider this issue we have as we want this to be (well it almost is besides this :) ) the best form software for joomla.

Now many designers add subscription boxes that fit nicely into a small area and cant be "pushed" down or it breaks the design.

e.g tontinefibres.com.au/

There are 2 ways around this.

1) Highlight the fields required in a different color

2) Have a popup box (ajax would be great if we want to stay current) that shows the errors.

This has been covered in a few posts as i have been looking for solution.

Many of us are not developers but can just install modules and adjust settings so it would be great if these things could be integrated.

If not, can you please give us instructions on how we can do it.

Many many thanks
The administrator has disabled public write access.

Re:Is it possible to highlight invalid fields? 14 years 5 months ago #11961

Hi, if we're keeping score on this one, add me to the "I'd like to see this feature as well" side.

Cheers,

Tony
The administrator has disabled public write access.

Re:Is it possible to highlight invalid fields? 14 years 5 months ago #11972

  • daajestaa
  • daajestaa's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 15
  • Thank you received: 3
*BUMP*

Any ideas? Surely there's someone out there who has an inkling on how to approach this. It would be such a great feature that I'd be willing to pay to get it done.

Mods... how much to have this added to RSForms?

Anyone else out there reckon they could take it on?
The administrator has disabled public write access.

Re: Is it possible to highlight invalid fields? 13 years 3 months ago #16187

  • daajestaa
  • daajestaa's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 15
  • Thank you received: 3
Yeehah! I have finally worked it out!!

If anyone is still looking for this solution, this is what worked for me.

Add the following to your templates CSS file:

.formRed {
color: #be1522;
font-weight: bold;
}

input.rsform-error {
background-color: #be1522;
color: #ffffff !important;
}

span.formClr {
display: none;
}

This hides the error message but turns the field red. The class input.rsform-error is only displayed if the form detects an error in a field so this addition to the CSS will only highlight fields that have an error.

Of course you can choose any colour that suits you but I have used red. I have also added a declaration to make the text white when the field is highlighted in red.

I hope this helps...
The administrator has disabled public write access.
The following user(s) said Thank You: calman

Re: Is it possible to highlight invalid fields? 12 years 4 months ago #20795

  • sergio6
  • sergio6's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 2
I insert this code in template, but don' work :(

I not appear any how too
The administrator has disabled public write access.

Is it possible to highlight invalid fields? 9 years 11 months ago #31164

Thanks! I altered the CSS above and this worked for me:

.rsform-error { border-color: #d02121 !important; }

Components > RS Form! Pro > Manage Form > "Select your form" > Properties > CSS and Javascript

I also edited the layout for use with the UiKit form component and added "uk-hidden" to hide the formValidation text.
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!