| @@ 1784-1797 (lines=14) @@ | ||
| 1781 | <input type="checkbox" name="default_options[', $setting['id'], ']" id="', $setting['id'], '"', !empty($context['member']['options'][$setting['id']]) ? ' checked' : '', ' value="1">'; |
|
| 1782 | ||
| 1783 | // How about selection lists, we all love them |
|
| 1784 | elseif ($setting['type'] == 'list') |
|
| 1785 | { |
|
| 1786 | echo ' |
|
| 1787 | <select name="default_options[', $setting['id'], ']" id="', $setting['id'], '"', '>'; |
|
| 1788 | ||
| 1789 | foreach ($setting['options'] as $value => $label) |
|
| 1790 | echo ' |
|
| 1791 | <option value="', $value, '"', $value == $context['member']['options'][$setting['id']] ? ' selected' : '', '>', $label, '</option>'; |
|
| 1792 | ||
| 1793 | echo ' |
|
| 1794 | </select>'; |
|
| 1795 | } |
|
| 1796 | // A textbox it is then |
|
| 1797 | else |
|
| 1798 | { |
|
| 1799 | if (isset($setting['type']) && $setting['type'] == 'number') |
|
| 1800 | { |
|
| @@ 614-627 (lines=14) @@ | ||
| 611 | </dd>'; |
|
| 612 | ||
| 613 | // A list with options? |
|
| 614 | elseif ($setting['type'] == 'list') |
|
| 615 | { |
|
| 616 | echo ' |
|
| 617 | <dd> |
|
| 618 | <select name="', !empty($setting['default']) ? 'default_' : '', 'options[', $setting['id'], ']" id="', $setting['id'], '">'; |
|
| 619 | ||
| 620 | foreach ($setting['options'] as $value => $label) |
|
| 621 | echo ' |
|
| 622 | <option value="', $value, '"', $value == $setting['value'] ? ' selected' : '', '>', $label, '</option>'; |
|
| 623 | ||
| 624 | echo ' |
|
| 625 | </select> |
|
| 626 | </dd>'; |
|
| 627 | } |
|
| 628 | // A Textarea? |
|
| 629 | elseif ($setting['type'] == 'textarea') |
|
| 630 | { |
|