Creating a colorized box for specific sections

Erica Pitcock created the topic: Creating a colorized box for specific sections

I'm creating a super long form for a insurance company. My client is asking if each section can be colorized. Please see screen shot. I was wondering how I can do this?

#21805
Attachments:

Please Log in or Create an account to join the conversation.


Support replied the topic: Creating a colorized box for specific sections

Dear Erica,

Please add the following code to Form Options > Javascript section of your form:

jQuery(document).ready(function () {
    var sectionColors = [ "black", "#cc0000" ];
    var index = 1;
    var length = sectionColors.length;
    jQuery(".wdform_section").each(function () {
         jQuery(this).css("background-color", sectionColors[index % length]);
         index++;
    });
})

Please define the colors in sectionColors.
Thank you.


Best regards,
Web-Dorado team


Joomla extensions ,
Wordpress plugins ,
Drupal modules
#21829

Please Log in or Create an account to join the conversation.


Erica Pitcock replied the topic: Creating a colorized box for specific sections

So for each section I want to colorize how do I do that with the code you provided?

#21846

Please Log in or Create an account to join the conversation.


Erica Pitcock replied the topic: Creating a colorized box for specific sections

This looks like it only colorizes all sections not a specific section.

#21847

Please Log in or Create an account to join the conversation.


Support replied the topic: Creating a colorized box for specific sections

Dear Erica,

Please separate your form's sections with section breaks.
Thank you.


Best regards,
Web-Dorado team


Joomla extensions ,
Wordpress plugins ,
Drupal modules
#21883

Please Log in or Create an account to join the conversation.


Erica Pitcock replied the topic: Creating a colorized box for specific sections

I did that and I'm still getting the same div tag. I need a separate class for each section so each section can have a different color background. Like the example screenshot from my initial post.

#22240

Please Log in or Create an account to join the conversation.


Support replied the topic: Creating a colorized box for specific sections

Dear Erica,

Could you please contact us to [email protected] and let us to take a look at this? Please mention the full link to your forum post in your e-mail.

Thank you.


Best regards,
Web-Dorado team


Joomla extensions ,
Wordpress plugins ,
Drupal modules
#22253

Please Log in or Create an account to join the conversation.


Time to create page: 0.197 seconds
Powered by Kunena Forum

WORLD-CLASS SUPPORT

We are here for you every step of the way. Turn to our support with any questions you might have about our products and services. Our experienced customer care team is available to help you as fast as we possibly can.

Contact us