Skip to content

Instantly share code, notes, and snippets.

@ashhitch
Last active August 14, 2016 06:33
Show Gist options
  • Select an option

  • Save ashhitch/b4e25c79a8df4c27407a6b526502c0a6 to your computer and use it in GitHub Desktop.

Select an option

Save ashhitch/b4e25c79a8df4c27407a6b526502c0a6 to your computer and use it in GitHub Desktop.
Contact7 WordPress Plugin Bootstrap 4 Styles
<div class="form-group">
<label>Your Name</label>
[text* your-name class:form-control]
</div>
<div class="form-group">
<label>Your Email</label>
[email* your-email class:form-control]
</div>
<div class="form-group">
<label>Your Telephone Number</label>
[tel your-tel class:form-control]
</div>
<div class="form-group">
<label>Your Message</label>
[textarea your-message class:form-control]
</div>
<div class="form-group">
[submit "Send" class:btn class:btn-primary]
</div>
.wpcf7-form-control:not(.wpcf7-submit):not(.wpcf7-range):not(.wpcf7-checkbox):not(.wpcf7-radio):not(.wpcf7-acceptance):not(.wpcf7-file) {
@extend .form-control;
}
.wpcf7-checkbox .wpcf7-list-item {
@extend .checkbox;
}
.wpcf7-checkbox.checkbox-inline .wpcf7-list-item {
@extend .checkbox-inline;
}
.wpcf7-radio .wpcf7-list-item {
@extend .radio;
}
.wpcf7-radio.radio-inline .wpcf7-list-item {
@extend .radio-inline;
}
.wpcf7-submit {
@extend .btn;
@extend .btn-primary;
}
/* Style validation */
div.wpcf7-validation-errors {
margin: 0;
@extend .alert;
@extend .alert-warning;
}
span.wpcf7-not-valid-tip {
@extend .form-text;
color: $state-danger-text;
}
.wpcf7-form-control.wpcf7-not-valid {
border-color: $state-danger-text !important;
}
<?php
define ('WPCF7_AUTOP', false );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment