Hello,
I would like to make one or more of the fields in a form not required, while making other fields required.
http://www.tsfexhibit.com/site/contactus
At this point the sender’s email and the message are required. I’d like to change that to name and email only but leave the other fields there as an option.
When I put in the variable “required” it has no effect.
{exp:email:contact_form user_recipients="false" recipients="[email protected],[email protected]" charset="utf-8"}
<input type="hidden" name="subject" size="40" value="TSF Website Contact Form" />
<label name="required[]"><span class="required">*</span> Name:</label>
<input name="name" type="text" id="name" class="formInput" />
<label name="required[]"><span class="required">*</span> E-mail:</label>
<input name="from" type="text" id="email" class="formInput" />
<label>Company Name:</label>
<input name="message[]" type="text" id="company" class="formInput" />
<label>Website:</label>
<input name="message[]" type="text" id="website" class="formInput" />
<label>Phone:</label>
<input name="message[]" type="text" id="phone" class="formInput" />
*(required)
<label>How Can We Help You:</label>
<textarea name="message[]" cols="35" rows="7" id="helpme"></textarea>
<input type="image" name="submit" src="{path='site_index'}siteimages/submit.png" value="SUBMIT" />
{/exp:email:contact_form}