24 Sep 2010, 11:55 AM
New Zenner
- Join Date:
- Jun 2010
- Posts:
- 7
- Plugin Contributions:
- 0
[Done v1.3.9g] Contact us drop down strange behavior
1.3.9e
I'm implementing recaptcha to my contact us form.
I haven't tested it to reproduce in default installation.
When I represented back with the contact us form because of errors (incomplete fields), the e-mail selection drop down box would corrupts itself
<label class="inputLabel" for="send-to">Kirim pesan kepada:</label>
<select name="send_to" id="send-to">
<option value="P" selected="selected">P</option>
<option value="" selected="selected"></option>
<option value="" selected="selected"></option>
<option value="0" selected="selected">Product Inquiry</option>
<option value="1">Billing</option>
<option value="2">Webmaster</option>
</select>
I somehow managed to fix it by resetting the $send_to_array in contact_us header.php
if (CONTACT_US_LIST !=''){
++ $send_to_array = array();
foreach(explode(",", CONTACT_US_LIST) as $k => $v) {
$send_to_array[] = array('id' => $k, 'text' => preg_replace('/\<[^*]*/', '', $v));
}
}
I don't have a clue as why it behaves that way.