在安装Contact Form 7插件后错过了原始联系表单样式

时间:2017-08-23 05:44:58

标签: php css wordpress html5 contact-form-7

我丢失了原始的联系表单css样式。安装Contact Form 7插件后,它显示默认联系表单7插件样式。有没有办法取回原始CSS样式的联系表格?

我的联系表格的原始Css样式如下,

 <form method="post" action="bat/rd-mailform.php" class="mailform">
          <input type="hidden" name="form-type" value="contact">
          <fieldset class="row">
            <label  data-add-placeholder="" class="grid_6">
              <input type="text" name="name" placeholder="Your Name" data-constraints="@LettersOnly @NotEmpty">
            </label>
            <label  data-add-placeholder="" class="grid_6">
              <input type="text" name="phone" placeholder="Your Phone" data-constraints="@Phone">
            </label>
            <label  data-add-placeholder="" class="grid_6">
              <input type="text" name="email" placeholder="Your Email" data-constraints="@Email @NotEmpty">
            </label>
            <label  data-add-placeholder="" class="grid_6">
              <input type="text" name="code" placeholder="Your City or Postal Code" data-constraints="@NotEmpty">
            </label>
            <label  data-add-placeholder="" class="grid_12">
              <textarea name="message" placeholder="Your Message" data-constraints="@NotEmpty"></textarea>
            </label>
            <div class="mfControls grid_12">
              <button type="submit" class="btn mfInfo">Send</button>
            </div>
          </fieldset>
        </form>

1 个答案:

答案 0 :(得分:0)

首先,您必须在联系表单7中应用您的代码/ HTML结构。

首先在表单中添加类和ID。

您可以通过将 html_id html_class 属性添加到[contact-form-7]短代码中,将任何ID和类添加到表单中。

Ex: [contact-form-7 html_id =&#34; your-id&#34; html_class =&#34;您的类邮件&#34;]

然后从插件代码中删除所有额外的标签,并像你的HTML结构一样创建代码结构,就像在<fieldset class="row">中包装所有字段一样,并根据你的代码在<label>中输入换行。

您的设计将自动应用于您的联系表格7。

谢谢:)

相关问题