<inp2:m_DefineElement name="config_edit_text">
	<input type="text" tabindex="<inp2:m_get param='tab_index'/>" name="<inp2:InputName field='$field'/>" id="<inp2:InputName field='$field'/>" value="<inp2:Field field='$field' />"<inp2:m_if check="m_Param" name="field_params"> <inp2:m_Param name="field_params"/><inp2:m_else/> style="width:100%"</inp2:m_if>/>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_edit_password">
	<input type="password" tabindex="<inp2:m_get param='tab_index'/>" primarytype="password" name="<inp2:InputName field='$field'/>" id="<inp2:InputName field='$field'/>" value="" />
	<inp2:m_Inc param="tab_index" by="1"/>
	<input type="password" tabindex="<inp2:m_get param='tab_index'/>" name="verify_<inp2:InputName field='$field'/>" id="verify_<inp2:InputName field='$field'/>" value="" />
	&nbsp;<span class="error" id="error_<inp2:InputName field="$field"/>"></span>

	<script type="text/javascript">
		addLoadEvent(
			function() {
				// fixes Firefox 2.0+ bug will password autocomplete
				document.getElementById('<inp2:InputName field="$field"/>').value = '';
				document.getElementById('verify_<inp2:InputName field="$field"/>').value = '';
			}
		);
	</script>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_edit_option">
		<option value="<inp2:m_param name='key'/>"<inp2:m_param name="selected"/>><inp2:m_param name="option"/></option>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_edit_select">
	<select name="<inp2:InputName field='$field'/>" id="<inp2:InputName field='$field'/>" tabindex="<inp2:m_get param='tab_index'/>">
		<inp2:PredefinedOptions field="$field" block="config_edit_option" selected="selected"/>
	</select>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_edit_multiselect">
	<select id="<inp2:InputName field='$field'/>_select" onchange="update_multiple_options('<inp2:InputName field='$field'/>');" tabindex="<inp2:m_get param='tab_index'/>" multiple>
		<inp2:PredefinedOptions field="$field" block="config_edit_option" selected="selected"/>
	</select>
	<input type="hidden" id="<inp2:InputName field='$field'/>" name="<inp2:InputName field='$field'/>" value="<inp2:Field field='$field'/>"/>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_edit_checkbox" field_class="">
	<input type="hidden" id="<inp2:InputName field='$field'/>" name="<inp2:InputName field='$field'/>" value="<inp2:Field field='$field' db='db'/>">
	<input tabindex="<inp2:m_get param='tab_index'/>" type="checkbox" id="_cb_<inp2:m_param name='field'/>" name="_cb_<inp2:InputName field='$field'/>" <inp2:Field field="$field" checked="checked" db="db"/> class="<inp2:m_param name="field_class"/>" onclick="update_checkbox(this, document.getElementById('<inp2:InputName field="$field"/>'))">
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_edit_textarea">
	<textarea tabindex="<inp2:m_get param='tab_index'/>" name="<inp2:InputName field='$field'/>" id="<inp2:InputName field='$field'/>" <inp2:m_param name="field_params" />><inp2:Field field="$field" /></textarea>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_radio_item">
	<input type="radio" <inp2:m_param name="checked"/> name="<inp2:InputName field="$field"/>" id="<inp2:InputName field="$field"/>_<inp2:m_param name="key"/>" value="<inp2:m_param name="key"/>"><label for="<inp2:InputName field="$field"/>_<inp2:m_param name="key"/>"><inp2:m_param name="option"/></label>&nbsp;
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_edit_radio">
		<inp2:PredefinedOptions field="$field" block="config_radio_item" selected="checked"/>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="cf_default_value">
	<inp2:ConfigFormElement PrefixSpecial="$PrefixSpecial" field="VariableValue" blocks_prefix="config_edit_" element_type_field="ElementType" value_list_field="ValueList"/>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="cf_default_caption">
	<td style="width: 500px;">
		<inp2:Field name="VariableName" result_to_var="error_field"/>
		<span class="<inp2:m_if check='HasError' field='$error_field' id_field='VariableName'>error-cell</inp2:m_if>">
		<inp2:Field field="Prompt" as_label="1" /></span><inp2:m_if check="IsRequired"><span class="field-required">&nbsp;*</span></inp2:m_if>:<inp2:m_if check="Field" name="HintLabel"><span>&nbsp;<img src="<inp2:m_TemplatesBase/>/img/hint_icon.png" width="12" height="13" title="<inp2:Field name='HintLabel' as_label='1' html_escape='1'/>" alt="<inp2:Field name='HintLabel' as_label='1' html_escape='1'/>"/></inp2:m_if>

		<inp2:m_if check="m_IsDebugMode">
			<br/><small style="color: gray;">[<inp2:Field field="DisplayOrder"/>] <inp2:Field field="VariableName"/></small>
		</inp2:m_if>
	</td>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_block">
	<inp2:m_inc param="tab_index" by="1"/>
	<inp2:m_if check="m_ParamEquals" name="show_heading" value="1">
		<tr class="subsectiontitle">
			<td colspan="2">
				<inp2:Field name="Heading" as_label="1"/>
	   		</td>
	   		<td align="right">
	   			<a class="config-header" href="javascript:toggle_section('<inp2:Field name="Heading"/>');" id="toggle_mark[<inp2:Field name="Heading"/>]" title="Collapse/Expand Section">[-]</a>
	   		</td>
		</tr>
	</inp2:m_if>

	<tr class="<inp2:m_odd_even odd='table-color1' even='table-color2'/>" id="<inp2:m_param name="PrefixSpecial"/>_<inp2:field field="$IdField"/>" header_label="<inp2:Field name="Heading"/>">
		<inp2:m_RenderElement name="cf_default_caption" pass_params="1"/>

		<td>
			<inp2:m_RenderElement name="$value_render_as" pass_params="1"/>
		</td>

		<td class="error"><inp2:Error id_field="VariableName"/>&nbsp;</td>
	</tr>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_block1">
	<inp2:m_inc param="tab_index" by="1"/>
	<inp2:m_if check="m_ParamEquals" name="show_heading" value="1">
		<tr class="subsectiontitle">
			<td colspan="2">
	    		<inp2:Field name="Heading" as_label="1"/>
	   		</td>
	   		<td align="right">
	   			<a class="config-header" href="javascript:toggle_section('<inp2:Field name="Heading"/>');" id="toggle_mark[<inp2:Field name="Heading"/>]" title="Collapse/Expand Section">[-]</a>
	   		</td>
		</tr>
	</inp2:m_if>

	<tr class="<inp2:m_odd_even odd='table-color1' even='table-color2'/>" id="<inp2:m_param name="PrefixSpecial"/>_<inp2:Field field="$IdField"/>" header_label="<inp2:Field name="Heading"/>">
		<inp2:m_RenderElement name="cf_default_caption" pass_params="1"/>

		<td>
			<nobr><inp2:m_RenderElement name="$value_render_as" pass_params="1"/>&nbsp;&nbsp;
</inp2:m_DefineElement>

<inp2:m_DefineElement name="config_block2">
			<inp2:m_RenderElement name="$value_render_as" pass_params="1"/></nobr>
		</td>
		<td class="error"><inp2:Error id_field="VariableName"/>&nbsp;</td>
	</tr>
</inp2:m_DefineElement>

<inp2:m_ModuleInclude template="config/custom_variables"/>
