如何在联系表单7中勾选复选框时出现新字段

时间:2013-12-31 01:59:05

标签: javascript jquery wordpress wordpress-plugin contact-form

我创建了一个带有wordpress联系表单7的表单,以下是短代码的样子:

<p>Name</p><br />
[text* your-name] </p>

<p>E-mail<br />
[email* your-email] </p>

<p>Subject<br />
[text your-subject] </p>

<p>Message<br />
[textarea your-message] </p>
<p>Where did you hear about us?<br />
[checkbox* your-country "Google search" "referral" "link" "Advertisement"]</p>

<p>[submit "Send"]</p>

但是在人们选择Google搜索的复选框区域中,我想要一个新字段显示在人们可以写出他们使用的关键字的位置。

任何帮助将不胜感激!

1 个答案:

答案 0 :(得分:1)

在[复选框*您的国家&#34; Google搜索&#34;旁边放置这个`[text * text-875&#34;请注明Google搜索关键字是否&#34;] &#34;转诊&#34; &#34;连结&#34; &#34;广告&#34;]

所以它看起来像这样

<p>Where did you hear about us?<br />
[checkbox* your-country "Google search" "referral" "link" "Advertisement"] [text* text-875 "please indacte if Google search key word)"] </p>

或者您可以在这样的单选按钮中执行此操作:

<p>Where did you hear about us?<br />   
[radio radio-100 class:radio-vertical "referral" "link" "Advertisement" "Google search, please indicate key word"] [text text-388] </p>