<ul class="tabs">
    <!-- active -->
    <!-- BEGIN DYNAMIC BLOCK: settingtab -->
        <li {settingactive}><a href="index.php?fuse=admin&amp;view={settingview}&amp;group={settinginternalname}">{settingname}</a></li>
    <!-- END DYNAMIC BLOCK: settingtab -->
    <!-- BEGIN DYNAMIC BLOCK: customemail_settingtab -->
        <li {customemail_settingactive}><a href="index.php?fuse=support&view=ViewAutoresponderTemplates">[l]Custom Templates[/l]</a></li>
    <!-- END DYNAMIC BLOCK: customemail_settingtab -->
</ul>


<div class="tab">
    <div class="table-summary" style="margin-bottom:10px;margin-top:10px">
        <h2>{ActiveSettingName} [l]Settings[/l]</h2>
    	[l]The settings below allow you to change the way your site looks and acts.  Make sure you fully understand what the setting's function is before making any changes.[/l]
    </div>

    <form name=settings method=post action="index.php?fuse=admin&action=UpdateSettings&group={settingGroup}&setting={selectedSetting}">

            <dl class="form noborder automation-options">
            <!-- BEGIN DYNAMIC BLOCK: settingRow -->
            
                <dt><label>{settingName}</label></dt>
                
                    <!-- BEGIN DYNAMIC BLOCK: yesnoType -->
                    <dd>
                        <input type="radio" id="value_{settingId}" name="value_{settingId}" value="0" {noSelected} {settingIsDisabled}> [l]No[/l]&nbsp;&nbsp;
                        <input type="radio"  id="value_{settingId}" name="value_{settingId}" value="1" {yesSelected} {settingIsDisabled}> [l]Yes[/l]
                    </dd>
                    <!-- Setting Description -->
                    <dd class="full desc">
                        <span>
                        {settingDescription}
                        <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                            <br />
                            (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                        <!-- END DYNAMIC BLOCK: settingHelp -->
                        </span>
                    </dd>
                    <!-- END DYNAMIC BLOCK: yesnoType -->
                    
                    <!-- BEGIN DYNAMIC BLOCK: passwordType -->
                    <dd>
                        <input type='password' name='value_{settingId}' size="40" value='{settingValue}' {settingIsDisabled}/>
                    </dd>
                    <!-- Setting Description -->
                    <dd class="full desc">
                        <span>
                        {settingDescription}
                        <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                            <br />
                            (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                        <!-- END DYNAMIC BLOCK: settingHelp -->
                        </span>
                    </dd>
                    <!-- END DYNAMIC BLOCK: passwordType -->
                    
                    <!-- BEGIN DYNAMIC BLOCK: textType -->
                    <dd>
                        <input type='text' name='value_{settingId}' size="50" value='{settingValue}' {settingIsDisabled}/>
                    </dd>
                    <!-- Setting Description -->
                    <dd class="full desc">
                        <span>
                        {settingDescription}
                        <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                            <br />
                            (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                        <!-- END DYNAMIC BLOCK: settingHelp -->
                        </span>
                    </dd>
                    <!-- END DYNAMIC BLOCK: textType -->

                    
                    <!-- BEGIN DYNAMIC BLOCK: optionsType -->
                    <dd>
                        <select name="value_{settingId}" {settingIsDisabled}>
                            <!-- BEGIN DYNAMIC BLOCK: optionsTypeItem -->
                            <option value="{optionTypeItemValue}" {optionTypeItemSelected}>{optionTypeItemLabel}&nbsp;&nbsp;</option>
                            <!-- END DYNAMIC BLOCK: optionsTypeItem -->
                        </select>
                    </dd>
                    <!-- Setting Description -->
                    <dd class="full desc">
                        <span>
                        {settingDescription}
                        <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                            <br />
                            (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                        <!-- END DYNAMIC BLOCK: settingHelp -->
                        </span>
                    </dd>
                    <!-- END DYNAMIC BLOCK: optionsType -->
                    
                    <!-- BEGIN DYNAMIC BLOCK: multipleoptionsType -->
                    <dd>
                        <select name="multiplevalue_{settingId}[]" multiple="true" size="5" style="width:230px;" {settingIsDisabled}>
                            <!-- BEGIN DYNAMIC BLOCK: multipleoptionsTypeItem -->
                            <option value="{optionTypeItemValue}" {optionTypeItemSelected}>{optionTypeItemLabel}&nbsp;&nbsp;</option>
                            <!-- END DYNAMIC BLOCK: multipleoptionsTypeItem -->
                        </select>
                    </dd>
                    <!-- Setting Description -->
                    <dd class="full desc">
                        <span>
                        {settingDescription}
                        <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                            <br />
                            (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                        <!-- END DYNAMIC BLOCK: settingHelp -->
                        </span>
                    </dd>
                    <!-- END DYNAMIC BLOCK: multipleoptionsType -->
                    
                    <!-- BEGIN DYNAMIC BLOCK: colorType -->
                    <dd>
                        <input type=text size=40 name='value_{settingId}' class=body value='{settingValue}' {settingIsDisabled} / >
                        <table width=100% cellpadding=1 cellspacing=0 border=1>
                            <tr>
                                <td bgcolor="{settingValue}"><font color="{settingValue}">&nbsp;</font></td>
                            </tr>
                        </table>
                    </dd>
                    <!-- Setting Description -->
                    <dd class="full desc">
                        <span>
                        {settingDescription}
                        <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                            <br />
                            (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                        <!-- END DYNAMIC BLOCK: settingHelp -->
                        </span>
                    </dd>
                    <!-- END DYNAMIC BLOCK: colorType -->
                    
                    
                    <!-- BEGIN DYNAMIC BLOCK: smallTextareaType -->
                        <!-- Setting Description -->
                        <dd class="full desc" style="border-bottom:0px;">
                            <span>
                            {settingDescription}
                            <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                                <br />
                                (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                            <!-- END DYNAMIC BLOCK: settingHelp -->
                            </span>
                        </dd>
                        <dd class="full" style="padding-bottom:15px;">
                            <textarea name="value_{settingId}" cols="50" rows="10" {settingIsDisabled}>{settingValue}</textarea>
                        </dd>
                    <!-- END DYNAMIC BLOCK: smallTextareaType -->
                    
                    
                    <!-- BEGIN DYNAMIC BLOCK: textareaType -->
                        <!-- Setting Description -->
                        <dd class="full desc" style="border-bottom:0px;">
                            <span>
                            {settingDescription}
                            <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                                <br />
                                (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                            <!-- END DYNAMIC BLOCK: settingHelp -->
                            </span>
                        </dd>
                        <dd class="full" style="padding-bottom:15px;">
                            <textarea name='value_{settingId}' cols="100" rows="20" {settingIsDisabled}>{settingValue}</textarea>
                        </dd>
                    <!-- END DYNAMIC BLOCK: textareaType -->
                    
                    <!-- BEGIN DYNAMIC BLOCK: richTextareaType -->
                        <!-- Setting Description -->
                        <dd class="full desc" style="border-bottom:0px;">
                            <span>
                            {settingDescription}
                            <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                                <br />
                                (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                            <!-- END DYNAMIC BLOCK: settingHelp -->
                            </span>
                        </dd>
                        <dd class="full" style="padding-bottom:15px;">
                            <script type="text/javascript">
                                var HTMLfieldEditor;
                                
                                Ext.onReady(function(){
                                    HTMLfieldEditor = new Ext.form.HtmlEditor({
                                        id:       'value_{settingId}',
                                        name:     'value_{settingId}',
                                        renderTo: 'ExtRichTextAreaEditor{settingId}',
                                        value:    '{settingValue}',
                                        x:        5,
                                        y:        40,
                                        width:    650,
                                        height:   250,
                                        {ExtSettingIsDisabled}
                                        hideMode: 'offsets'
                                    });
                                });
                            </script>
                            
                            <span id='ExtRichTextAreaEditor{settingId}'></span>
                        </dd>
                    <!-- END DYNAMIC BLOCK: richTextareaType -->
                    
                    <!-- BEGIN DYNAMIC BLOCK: dualTextareaType -->
                        <!-- Setting Description -->
                        <dd class="full desc"  style="border-bottom:0px;">
                            <span>
                            {settingDescription}
                            <!-- BEGIN DYNAMIC BLOCK: settingHelp -->
                                <br />
                                (<a href="#"  onMouseDown="openHelpWindow('{settingModule}', '{settingClass}', '{untranslatedEncodedSettingName}', 'menubar=no,scrollbars=yes,width=240,height=420')">{helpLinkLabel}</a>)<br />
                            <!-- END DYNAMIC BLOCK: settingHelp -->
                            </span>
                        </dd>
                        <dd class="full" style="padding-bottom:15px;">
                            <script type="text/javascript">
                                var HTMLfieldEditor;
                                var PlainTextFieldEditor;
                                var DualTextAreaEditor;
                                
                                Ext.onReady(function(){
                                    HTMLfieldEditor = new Ext.form.HtmlEditor({
                                        id:       'value_{settingId}_0',
                                        name:     'value_{settingId}_0',
                                        value:    '{settingValueHTML}',
                                        x:        5,
                                        y:        40,
                                        {ExtSettingIsDisabled}
                                        hideMode: 'offsets'
                                    });
                                    
                                    PlainTextFieldEditor = new Ext.form.TextArea({
                                        id:     'value_{settingId}_1',
                                        name:   'value_{settingId}_1',
                                        {ExtSettingIsDisabled}
                                        value:  '{settingValuePlainText}'
                                    });
                                    
                                    DualTextAreaEditor = new Ext.TabPanel({
                                        id:                 'DualTextAreaEditor{settingId}',
                                        renderTo:           'ExtDualTextAreaEditor{settingId}',
                                        //activeTab:          'tabPlainTextFieldEditor{settingId}',
                                        x:                  5,
                                        y:                  55,
                                        width:              650,
                                        height:             250,
                                        autoScrollTabs:     true,
                                        plain:              true,
                                        deferredRender :    false,
                                        layoutOnTabChange:  true,
                                        defaults:           {
                                            bodyStyle:  'padding:5px'
                                        },
                                        items:              [
                                            {
                                                id:     "tabHTMLfieldEditor{settingId}",
                                                name:   "tabHTMLfieldEditor{settingId}",
                                                cls:    'x-plain',
                                                title:  'HTML',
                                                layout: "fit",
                                                items:  [
                                                    HTMLfieldEditor
                                                ]
                                            },
                                            {
                                                id:     "tabPlainTextFieldEditor{settingId}",
                                                name:   "tabPlainTextFieldEditor{settingId}",
                                                cls:    'x-plain',
                                                title:  lang('Plain Text'),
                                                layout: "fit",
                                                items:  [
                                                    PlainTextFieldEditor
                                                ]
                                            }
                                        ],
                                        listeners:          {
                                            'render': {
                                                fn: function(){
                                                    this.activate('tabPlainTextFieldEditor{settingId}');
                                                    this.activate('tabHTMLfieldEditor{settingId}');
                                                }
                                            }
                                        }
                                    });
                                });
                            </script>
                            
                            <span id='ExtDualTextAreaEditor{settingId}'></span>
                        </dd>
                    <!-- END DYNAMIC BLOCK: dualTextareaType -->
                    
                    
            <!-- END DYNAMIC BLOCK: settingRow -->
            </dl>

            <!--BEGIN DYNAMIC BLOCK: updateButton -->
            <input type="hidden" name="settingsArray" value='{settingIds}'>
            <input type="submit" class="button" value='[l]update settings[/l]' onclick='check(form,form.elements.length);return false;'>
            <!--END DYNAMIC BLOCK: updateButton -->
               
    </form>
</div> <!-- tab -->