使用联系表单7插件动态添加删除字段

时间:2017-06-02 06:26:21

标签: wordpress contact-form-7

我想动态添加或删除字段,如jQuery,如下面的表单链接。我使用了联系表单7插件来显示表单。是否有与之相关的插件?

https://www.sanwebe.com/2013/03/addremove-input-fields-dynamically-with-jquery

1 个答案:

答案 0 :(得分:1)

查看Conditional Fields for Contact Form 7插件。关于如何设置条件表单,tutorial很容易理解。

Which fields would you like to view? [select pick-fields "Basic fields" "Advanced fields" "All fields"]

[group basic-fields]
<fieldset>
<legend>Basic Fields</legend>

Your name
[text name]

Your email
[text email]
</fieldset>

[/group]
[group advanced-fields]

<fieldset>
<legend>Advanced Fields</legend>

Your operating system
[select pick-os "Windows" "Mac" "Linux" "Android" "iOS" "Other"]
[group other][text other_os][/group]

Some advanced fields
[text adv]
</fieldset>

[/group]