• Resolved kissenefrega

    (@kissenefrega)


    Hi,
    I’m going to change the background color of a single submit button in a contact form 7. I gave a class name to that button (class:singoli).
    But if I add this css custom code:

    .wpcf7-form .singoli input[type=”submit”]{
    background-color:#74253d!important;
    color:#ffffff;
    }

    it does not work. May you know some tricks to help me?
    Thanks

Viewing 7 replies - 1 through 7 (of 7 total)
  • I think if you add a class to the button it would get added to the input, so your CSS should look like this:

    .wpcf7-form input.singoli {
    	background-color: #74253d !important;
    	color: #ffffff;
    }
    Thread Starter kissenefrega

    (@kissenefrega)

    Hi Howdy_McGee
    I solved with this:)

    .wpcf7-form-control.wpcf7-submit.singoli{
    background-color:#74253d!important;
    color:#ffffff !important;
    }

    I am having the same issue on a site I am helping update. How/where did you assign a class to the submit button?

    @haymjohnston Whenever creating the form, toward the top are the field buttons where you can add new fields to your form. The last button is a Submit where you can add an ID or class.

    this is what I see in my form creation tab, do you mind sending over the add class code. I am new to this ??

    <div class=”col-md-12 col-sm-12″>
    <div class=”col-lg-2″><label class=”text”>Name</div>
    <div class=”col-lg-10 box”>[text* your-name]</label></div>

    <div class=”col-lg-2″><label class=”text”>Email</div>
    <div class=”col-lg-10 box”>[email* your-email]</label></div>

    <div class=”col-lg-2″><label class=”text”>Phone#</div>
    <div class=”col-lg-10 box”>[tel* phone]</label></div>

    <div class=”col-lg-2″><label class=”text”>Subject</div>
    <div class=”col-lg-10 box”>[text your-subject]</label></div>

    <div class=”col-lg-2″><label class=”text”>Comment</div>
    <div class=”col-lg-10 box-area”>[textarea your-comment]</label></div>

    [submit “SUBMIT”]

    Replace submit with this:

    [submit class:submit-button "SUBMIT"]

    thank you so much!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Change single submit button bg-color’ is closed to new replies.