Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I am working on drupal 7 clientside validation module.On validation which displays error messages with 'error' class which is same as drupal's system error message's class.But I want seperate theming for clientside validation so I want to change the class 'error' to 'newerror' without hacking the module.I searched everything in web but most suggestions for altering error messages.I dont want to change systems error class.Any suggestions?
Comments
Comment #1
attiks CreditAttribution: attiks commentedI think it might be better to just add an extra class to it, so you can style them differently if you want to?
If so can you proivde a patch
Comment #2
hiranya CreditAttribution: hiranya commentedHi,thanks for your kind reply.But where I have to add class? in modules js file or doing some custom module.I found no way around without hacking it.Sorry if I misunderstood you!
Comment #3
attiks CreditAttribution: attiks commented#2 You can change it into the module and upload your changes here, so we can add it to the module. More background info on how to do this can you find at https://drupal.org/node/707484
Comment #4
attiks CreditAttribution: attiks commentedThe containing divs are created in http://drupalcode.org/project/clientside_validation.git/blob/refs/heads/...
Comment #5
hiranya CreditAttribution: hiranya commentedHi,
In clientside_validation.js line 280 I changed errorClass:error to errorClass:newerror.working fine.But I dnt think it's a good idea.