Commit | Line | Data |
---|---|---|
6f2bc235 | 1 | <label><input type="checkbox" id="search_{$option->optionName}" name="searchOptions[{$option->optionName}]"{if $searchOption} checked{/if}> {lang}wcf.user.option.searchRadioButtonOption{/lang}</label> |
67b82019 MW |
2 | <select id="{$option->optionName}" name="values[{$option->optionName}]"{if !$searchOption} disabled{/if}{if $option->required} required{/if}> |
3 | {if !$allowEmptyValue|empty}<option value="">{lang}wcf.global.noSelection{/lang}</option>{/if} | |
4 | {foreach from=$selectOptions key=key item=selectOption} | |
5 | <option value="{$key}"{if $value == $key} selected{/if}>{lang}{@$selectOption}{/lang}</option> | |
6 | {/foreach} | |
7 | </select> | |
567b90a3 MS |
8 | |
9 | <script data-relocate="true"> | |
567b90a3 MS |
10 | $(function() { |
11 | $('#search_{$option->optionName}').change(function(event) { | |
12 | if ($(event.currentTarget).prop('checked')) { | |
13 | $('#{$option->optionName}').enable(); | |
14 | } | |
15 | else { | |
16 | $('#{$option->optionName}').disable(); | |
17 | } | |
18 | }); | |
19 | }); | |
567b90a3 | 20 | </script> |