<inp2:m_DefineElement name="combined_header" permission_type="view" perm_section="" perm_prefix="" perm_event="" system_permission="1" title_preset="" tab_preset="" additional_title_render_as="" additional_blue_bar_render_as="" pagination_prefix="" parent="1" grid="Default">
	<inp2:m_if check="m_Param" name="perm_section" inverse="1">
		<inp2:adm_SectionInfo section="$section" info="perm_section" result_to_var="perm_section"/>
	</inp2:m_if>
	<inp2:m_if check="m_Param" name="permission_type">
		<inp2:m_RequireLogin permissions="{$perm_section}.{$permission_type}" perm_event="$perm_event" perm_prefix="$perm_prefix" system="$system_permission"/>
	<inp2:m_else/>
		<inp2:m_RequireLogin permissions="{$perm_section}" perm_event="$perm_event" perm_prefix="$perm_prefix" system="$system_permission"/>
	</inp2:m_if>
	<inp2:m_if check="m_Param" name="prefix" inverse="1"><inp2:adm_SectionInfo section="$section" info="SectionPrefix" result_to_var="prefix"/></inp2:m_if>
	<inp2:m_if check="m_get" var="m_wid" inverse="1">
		<inp2:m_if check="m_GetConfig" name="UseSmallHeader">
			<img src="img/spacer.gif" height="8" width="1" alt=""/>
		<inp2:m_else/>
			<table cellpadding="0" cellspacing="0" border="0" width="100%">
				<!--## <tr<inp2:m_ifnot check="m_ModuleEnabled" module="Proj-Base"> style="background: url(<inp2:adm_SectionInfo section="$section" parent="$parent" info="module_path"/>img/logo_bg.gif) no-repeat top right; height: 55px;"</inp2:m_ifnot>> ##-->
				<tr>
					<td valign="top" class="admintitle" align="left" <!--##style="padding-top: 10px; padding-bottom: 10px;"##-->>
			    		<img width="46" height="46" src="<inp2:adm_SectionInfo section='$section' parent='$parent' info='module_path'/>img/icons/icon46_<inp2:adm_SectionInfo section='$section' parent='$parent' info='icon'/>.png" align="absmiddle" title="<inp2:adm_SectionInfo section='$section' parent='$parent' info='label' no_editing='1'/>" alt=""/><inp2:adm_SectionInfo section="$section" parent="$parent" info="label"/>
			   		</td>
			   		<inp2:m_if check="m_Param" name="additional_title_render_as">
						<inp2:m_RenderElement name="$additional_title_render_as" pass_params="1"/>
					</inp2:m_if>
				</tr>
			</table>
		</inp2:m_if>
	<inp2:m_else/>
		<inp2:m_if check="m_Param" name="additional_title_render_as">
			<table cellpadding="0" cellspacing="0" border="0" width="100%">
				<!--## <tr<inp2:m_ifnot check="m_ModuleEnabled" module="Proj-Base"> style="background: url(<inp2:adm_SectionInfo section="$section" parent="$parent" info="module_path"/>img/logo_bg.gif) no-repeat top right; height: 55px;"</inp2:m_ifnot>> ##-->
				<tr>
					<inp2:m_RenderElement name="$additional_title_render_as" pass_params="1"/>
				</tr>
			</table>
		</inp2:m_if>
	</inp2:m_if>

	<inp2:$prefix_ModifyUnitConfig pass_params="1"/>

	<inp2:m_if check="m_Param" name="tabs">
		<inp2:m_include t="$tabs" pass_params="1"/>
	</inp2:m_if>

	<inp2:m_if check="m_Param" name="tab_preset">
		<inp2:m_RenderElement name="edit_tabs" prefix="$prefix" preset_name="$tab_preset"/>
	</inp2:m_if>

	<table border="0" cellpadding="2" cellspacing="0" class="bordered-no-bottom" width="100%" style="height: 30px;">
		<tr>
			<td class="header_left_bg" nowrap="nowrap" style="vertical-align: middle;">
				<inp2:adm_SectionInfo section="$section" info="label" result_to_var="default_title"/>
				<inp2:adm_SectionInfo section="$section" parent="$parent" info="label" result_to_var="group_title"/>
				<span class="tablenav_link" id="blue_bar">
					<inp2:$prefix_SectionTitle title_preset="$title_preset" section="$section" title="$default_title" group_title="$group_title" cut_first="100" pass_params="true"/>
				</span>
			</td>
			<td align="right" class="tablenav" style="vertical-align: middle;">
				<inp2:m_if check="m_Param" name="additional_blue_bar_render_as">
					<inp2:m_RenderElement name="$additional_blue_bar_render_as" pass_params="1"/>
				<inp2:m_else/>
					<inp2:m_if check="m_Param" name="pagination">
						<inp2:$prefix_SelectParam possible_names="pagination_prefix,prefix" result_to_var="pagination_prefix"/>
						<inp2:m_RenderElement name="grid_pagination_elem" PrefixSpecial="$pagination_prefix" pass_params="1"/>
					</inp2:m_if>
				</inp2:m_if>
			</td>
		</tr>
	</table>

	<script type="text/javascript">
		var $visible_toolbar_buttons = <inp2:m_if check="{$prefix}_VisibleToolbarButtons" title_preset="$title_preset">[<inp2:$prefix_VisibleToolbarButtons title_preset="$title_preset"/>]<inp2:m_else/>true</inp2:m_if>;
		var $allow_dbl_click = ($visible_toolbar_buttons === true) || in_array('dbl-click', $visible_toolbar_buttons);

		set_window_title( $.trim( $('#blue_bar').text().replace(/\s+/g, ' ') ) + ' - <inp2:m_Phrase label="la_AdministrativeConsole" js_escape="1"/>');
		setHelpLink('<inp2:lang.current_Field name="UserDocsUrl" js_escape="1"/>', '<inp2:m_Param name="title_preset" js_escape="1"/>');
	</script>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_original_label">
	<td><inp2:$prefix.original_Field field="$field" nl2br="1"/></td>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="subsection" prefix="" fields="" colspan="3">
	<inp2:m_if check="m_Param" name="prefix" equals_to="">
		<tr class="subsectiontitle">
			<td colspan="<inp2:m_param name='colspan'/>"><inp2:m_phrase label="$title"/></td>
		</tr>
	<inp2:m_else/>
		<inp2:m_if check="{$prefix}_FieldsVisible" fields="$fields">
			<tr class="subsectiontitle">
				<td colspan="<inp2:m_param name='colspan'/>"><inp2:m_phrase label="$title"/></td>
				<inp2:m_if check="{$prefix}_DisplayOriginal" pass_params="1">
					<td><inp2:m_phrase name="$original_title"/></td>
				</inp2:m_if>
			</tr>
		</inp2:m_if>
	</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="form_message" id="">
	<table width="100%" cellspacing="0" cellpadding="4" class="warning-table"<inp2:m_if check="m_Param" name="id"> id="<inp2:m_Param name='id'/>"</inp2:m_if>>
		<tr>
			<td valign="top" class="form-warning">
				<inp2:m_Param name="content"/>
			</td>
		</tr>
	</table>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="default_field_caption_element">
	<label for="<inp2:m_param name='NamePrefix'/><inp2:{$prefix}_InputName field='$field'/>">
		<span class="<inp2:m_if check='{$prefix}_HasError' field='$field'>error-cell</inp2:m_if>"><inp2:m_if check="m_Param" name="title"><inp2:m_phrase label="$title"/></inp2:m_else/><inp2:m_Param name="title_text"/></inp2:m_if></span></span><inp2:m_if check="{$prefix}_IsRequired" field="$field"><span class="field-required">&nbsp;*</span></inp2:m_if>:<inp2:m_if check="m_Param" name="hint_label"><span>&nbsp;<img src="<inp2:m_TemplatesBase/>/img/hint_icon.png" width="12" height="13" title="<inp2:m_Phrase label='$hint_label' html_escape='1'/>" alt="<inp2:m_Phrase label='$hint_label' html_escape='1'/>"/></inp2:m_if>
	</label>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_field_caption" title="" title_text="" hint_label="" NamePrefix="">
	<inp2:m_inc param="tab_index" by="1"/>
	<td class="label-cell" onmouseover="show_form_error('<inp2:m_Param name='prefix' js_escape='1'/>', '<inp2:m_Param name='field' js_escape='1'/>')" onmouseout="hide_form_error('<inp2:m_Param name='prefix' js_escape='1'/>')">
		<inp2:m_if check="m_Param" name="title">
			<inp2:m_RenderElement name="$caption_render_as" pass_params="1"/>
		<inp2:m_else/>
			<inp2:m_if check="m_Param" name="title_text">
				<inp2:m_RenderElement name="$caption_render_as" pass_params="1"/>
			<inp2:m_else/>
				&nbsp;
			</inp2:m_if>
		</inp2:m_if>
	</td>
	<td class="control-mid">&nbsp;</td>
	<script type="text/javascript">
		if (typeof(fields['<inp2:m_Param name="prefix" js_escape="1"/>']) == 'undefined') {
			fields['<inp2:m_Param name="prefix" js_escape="1"/>'] = new Object();
		}
		fields['<inp2:m_Param name="prefix" js_escape="1"/>']['<inp2:m_Param name="field" js_escape="1"/>'] = '<inp2:m_if check="m_Param" name="title"><inp2:m_phrase label="$title" js_escape="1"/></inp2:m_else/><inp2:m_Param name="title_text" js_escape="1"/></inp2:m_if>'
	</script>
</inp2:m_DefineElement>

<!--## design default parameters only avaible in design block ##-->
<inp2:m_DefineElement name="form_row" error_field_suffix="" has_caption="1" caption_render_as="default_field_caption_element" style="" hint_label="" is_last="">
	<inp2:m_if check="{$prefix}_FieldVisible" field="$field">
		<tr class="<inp2:m_odd_even odd='edit-form-odd' even='edit-form-even'/>" id="<inp2:$prefix_InputName field='$field'/>_row"<inp2:m_if check="m_Param" name="row_style"> style="<inp2:m_Param name='row_style'/>"</inp2:m_if>>
			<inp2:m_if check="m_Param" name="has_caption">
				<inp2:m_RenderElement name="inp_edit_field_caption" field="{$field}{$error_field_suffix}" pass_params="1"/>
			</inp2:m_if>

			<inp2:m_Param name="content" pass_params="1"/>

			<inp2:m_RenderElement name="inp_edit_error" prefix="$prefix" field="{$field}{$error_field_suffix}"/>

			<inp2:m_if check="{$prefix}_DisplayOriginal" pass_params="1">
				<inp2:m_RenderElement prefix="$prefix" field="$field" name="inp_original_label"/>
			</inp2:m_if>
		</tr>
	</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_label" style="" format="" db="" as_label="" currency="" no_special="" nl2br="0" with_hidden="0" after_text="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell" valign="top">
			<span style="<inp2:m_Param name='style'/>" id="<inp2:$prefix_InputName field='$field'/>">
				<inp2:{$prefix}_Field field="$field" format="$format" as_label="$as_label" currency="$currency" nl2br="$nl2br" no_special="$no_special"/><inp2:m_Param name="after_text"/>
			</span>

			<inp2:m_if check="m_Param" name="with_hidden">
				<input type="hidden" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field' db='$db'/>">
			</inp2:m_if>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_id_label">
	<inp2:m_ifnot check="Field" field="$field" equals_to="|0">
		<inp2:m_RenderElement name="inp_label" pass_params="true"/>
	</inp2:m_ifnot>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_error">
	<script type="text/javascript">
		add_form_error('<inp2:m_Param name="prefix" js_escape="1"/>', '<inp2:m_Param name="field" js_escape="1"/>', '<inp2:{$prefix}_InputName field="$field"/>', '<inp2:{$prefix}_Error field="$field" js_escape="1"/>')
	</script>
	<!--##<td class="error-cell"><inp2:{$prefix}_Error field="$field"/>&nbsp;</td>##-->
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_box" class="" format="" maxlength="" onblur="" onchange="" size="" onkeyup="" allow_html="" edit_template="popups/editor" style="width: 100%" after_text="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<input style="<inp2:m_Param name='style'/>" type="text" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field' format='$format'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" maxlength="<inp2:m_param name='maxlength'/>" class="<inp2:m_param name='class'/>" onblur="<inp2:m_Param name='onblur'/>" onkeyup="<inp2:m_Param name='onkeyup'/>" onchange="<inp2:m_Param name='onchange'/>"><inp2:m_Param name="after_text"/>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_password" class="" size="" style="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<input style="<inp2:m_Param name='style'/>" type="password" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field name='{$field}_plain'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" class="<inp2:m_param name='class'/>" />

			<script type="text/javascript">
				$(document).ready(
					function() {
						<inp2:m_ifnot check="{$prefix}_Field" name="{$field}_plain">
							$('#' + jq('<inp2:{$prefix}_InputName field="$field"/>')).val('');
						</inp2:m_ifnot>
					}
				);
			</script>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_upload" class="" size="" thumbnail="" style="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<inp2:m_if check="m_Param" name="thumbnail">
				<inp2:m_if check="{$prefix}_FieldEquals" name="$field" value="" inverse="inverse">
					<img src="<inp2:{$prefix}_Field field='$field' format='resize:{$thumbnail}'/>" alt=""/><br />
					<table cellpadding="0" cellspacing="0">
						<tr>
							<td>
								<input type="hidden" id="<inp2:{$prefix}_InputName field='Delete{$field}'/>" name="<inp2:{$prefix}_InputName field='Delete{$field}'/>" value="0" />
								<input type="checkbox" id="_cb_<inp2:{$prefix}_InputName field='Delete{$field}'/>" onchange="update_checkbox(this, document.getElementById('<inp2:{$prefix}_InputName field='Delete{$field}'/>'));">
							</td>
							<td>
								<label for="_cb_<inp2:{$prefix}_InputName field='Delete{$field}'/>"><inp2:m_phrase name="la_btn_Delete"/></label>
							</td>
						</tr>
					</table>
				</inp2:m_if>
				<input type="file" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" class="<inp2:m_param name='class'/>">
			<inp2:m_else/>
				<input type="file" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" class="<inp2:m_param name='class'/>">
				<inp2:m_if check="{$prefix}_FieldEquals" name="$field" value="" inverse="inverse">
					(<inp2:{$prefix}_Field field="$field"/>)
				</inp2:m_if>
			</inp2:m_if>
			<input type="hidden" name="<inp2:{$prefix}_InputName field='$field'/>[upload]" id="<inp2:{$prefix}_InputName field='$field'/>[upload]" value="<inp2:{$prefix}_Field field='$field'/>">
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_box_ml">
	<inp2:m_RenderElement name="inp_edit_box" format="no_default" pass_params="true"/>

	<!--##
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="label-cell" valign="top">
			<span class="<inp2:m_if check='{$prefix}_HasError' field='$field'>error-cell</inp2:m_if>" >
			<inp2:m_phrase label="$title"/><inp2:m_if check="{$prefix}_IsRequired" field="$field"><span class="field-required">&nbsp;*</span></inp2:m_if>:</span><br>
			<a href="javascript:PreSaveAndOpenTranslator('<inp2:m_param name='prefix'/>', '<inp2:m_param name='field'/>', 'popups/translator');" title="<inp2:m_Phrase label='la_Translate'/>"><img src="img/icons/icon24_translate.png" style="cursor:hand" border="0"></a>
		</td>
		<td class="control-cell">
			<input style="<inp2:m_Param name='style'/>" type="text" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field' format='no_default'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" maxlength="<inp2:m_param name='maxlength'/>" class="<inp2:m_param name='class'/>" onblur="<inp2:m_Param name='onblur'/>">
		</td>
	</inp2:m_RenderElement>
	##-->
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_swf_upload" class="" style="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<div style="width: 63px; height: 21px;" id="<inp2:{$prefix}_InputName field='$field'/>_place_holder">
				&nbsp;
			</div>

			<div id="<inp2:{$prefix}_InputName field='$field'/>_queueinfo" class="uploader-queue"></div>

			<input type="hidden" name="<inp2:{$prefix}_InputName field='$field'/>[upload]" id="<inp2:{$prefix}_InputName field='$field'/>[upload]" value="<inp2:{$prefix}_Field field='$field' format='file_names'/>">
			<input type="hidden" name="<inp2:{$prefix}_InputName field='$field'/>[tmp_ids]" id="<inp2:{$prefix}_InputName field='$field'/>[tmp_ids]" value="">
			<input type="hidden" name="<inp2:{$prefix}_InputName field='$field'/>[tmp_names]" id="<inp2:{$prefix}_InputName field='$field'/>[tmp_names]" value="">
			<input type="hidden" name="<inp2:{$prefix}_InputName field='$field'/>[tmp_deleted]" id="<inp2:{$prefix}_InputName field='$field'/>[tmp_deleted]" value="">

			<script type="text/javascript">
				UploadsManager.AddUploader('<inp2:{$prefix}_InputName field="$field"/>',
					{
						baseUrl: '<inp2:m_TemplatesBase />',
						allowedFiletypesDescription : '<inp2:{$prefix}_FieldOption field="$field" option="files_description" result_to_var="files_description"/><inp2:m_Phrase name="$files_description" js_escape="1"/>',
						allowedFiletypes : '<inp2:{$prefix}_FieldOption field="$field" option="file_types"/>',
						allowedFilesize : '<inp2:{$prefix}_FieldOption field="$field" option="max_size"/>',
						multiple : '<inp2:{$prefix}_FieldOption field="$field" option="multiple"/>',
						prefix : '<inp2:m_Param name="prefix"/>',
						field : '<inp2:m_Param name="field"/>',
						thumb_format: '<inp2:{$prefix}_FieldOption field="$field" option="thumb_format"/>',
						urls : '<inp2:{$prefix}_Field field="$field" format="file_urls" js_escape="1"/>',
						names : '<inp2:{$prefix}_Field field="$field" format="file_names" js_escape="1"/>',
						sizes : '<inp2:{$prefix}_Field field="$field" format="file_sizes" js_escape="1"/>',
						flashsid : '<inp2:m_SID/>',
						uploadURL : '<inp2:m_t pass="all,$prefix" {$prefix}_event="OnUploadFile" js_escape="1" no_amp="1" />',
						deleteURL : '<inp2:m_t pass="all,$prefix" {$prefix}_event="OnDeleteFile" field="#FIELD#" file="#FILE#" js_escape="1" no_amp="1"/>',
						tmp_url : '<inp2:m_t pass="all,$prefix" {$prefix}_event="OnViewFile" tmp="1" field="#FIELD#" file="#FILE#" id="#ID#" js_escape="1" no_amp="1" />',

						// Button settings
						buttonImageURL: 'img/upload.png',	// Relative to the Flash file
						buttonWidth: 63,
						buttonHeight: 21,
						buttonText: '<span class="theFont">Browse</span>',
						buttonTextStyle: ".theFont { font-size: 12; font-family: arial, sans}",
						buttonTextTopPadding: 2,
						buttonTextLeftPadding: 9,
						buttonPlaceholderId: '<inp2:{$prefix}_InputName field="$field"/>_place_holder'
					}
				)
			</script>

		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_hidden" db="">
	<input type="hidden" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field' db='$db'/>">
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_date" class="" error_field_suffix="_date">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<input type="text" name="<inp2:{$prefix}_InputName field='{$field}_date'/>" id="<inp2:{$prefix}_InputName field='{$field}_date'/>" value="<inp2:{$prefix}_Field field='{$field}_date' format='_input_'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:{$prefix}_Format field='{$field}_date' input_format='1' edit_size='edit_size'/>" class="<inp2:m_param name='class'/>" datepickerIcon="<inp2:m_ProjectBase/>core/admin_templates/img/calendar_icon.gif">&nbsp;
			<img src="img/calendar_icon.gif" id="cal_img_<inp2:{$prefix}_InputName field='{$field}'/>"
					     style="cursor: pointer; margin-right: 5px"
					     title="Date selector"
					/>
			<span class="small">(<inp2:{$prefix}_Format field="{$field}_date" input_format="1" human="true"/>)</span>
			<script type="text/javascript">
				Calendar.setup({
			        inputField		:	"<inp2:{$prefix}_InputName field='{$field}_date'/>",
			        ifFormat		:	Calendar.phpDateFormat("<inp2:{$prefix}_Format field='{$field}_date' input_format='1'/>"),
			        button			:	"cal_img_<inp2:{$prefix}_InputName field='{$field}'/>",
			        align			:	"br",
			        singleClick		:	true,
			        showsTime		:	true,
			        weekNumbers		:	false,
			        firstDay		:	<inp2:m_GetConfig var="FirstDayOfWeek"/>,
			        onUpdate	:	function(cal) {
			        	runOnChange('<inp2:$prefix_InputName field='{$field}_date'/>');
			       	}
				});
			</script>
			<input type="hidden" name="<inp2:{$prefix}_InputName field='{$field}_time'/>" id="<inp2:{$prefix}_InputName field='{$field}_time' input_format='1'/>" value="">
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_time" class="" error_field_suffix="_time">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<input type="text" name="<inp2:{$prefix}_InputName field='{$field}_time'/>" id="<inp2:{$prefix}_InputName field='{$field}_time'/>" value="<inp2:{$prefix}_Field field='{$field}_time' format='_input_'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:{$prefix}_Format field='{$field}_time' input_format='1' edit_size='edit_size'/>" class="<inp2:m_param name='class'/>">&nbsp;
			<span class="small">(<inp2:{$prefix}_Format field="{$field}_time" input_format="1" human="true"/>)</span>

			<input type="hidden" name="<inp2:{$prefix}_InputName field='{$field}_date'/>" id="<inp2:{$prefix}_InputName field='{$field}_date' input_format='1'/>" value="">
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_date_time" class="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<!-- <input type="hidden" id="<inp2:{$prefix}_InputName field='$field'/>" name="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field' db='db'/>"> -->
			<input type="text" name="<inp2:{$prefix}_InputName field='{$field}_date'/>" id="<inp2:{$prefix}_InputName field='{$field}_date'/>" value="<inp2:{$prefix}_Field field='{$field}_date' format='_input_'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:{$prefix}_Format field='{$field}_date' input_format='1' edit_size='edit_size'/>" class="<inp2:m_param name='class'/>" datepickerIcon="<inp2:m_ProjectBase/>core/admin_templates/img/calendar_icon.gif">
			<img src="img/calendar_icon.gif" id="cal_img_<inp2:{$prefix}_InputName field="{$field}"/>"
					     style="cursor: pointer; margin-right: 5px"
					     title="Date selector"
					/>
				<span class="small">(<inp2:{$prefix}_Format field="{$field}_date" input_format="1" human="true"/>)</span>
			<input type="hidden" id="full_date_<inp2:{$prefix}_InputName field='{$field}'/>" value="<inp2:{$prefix}_Field field='{$field}' format=''/>" />
			<script type="text/javascript">
				Calendar.setup({
			        inputField	:	"full_date_<inp2:{$prefix}_InputName field='{$field}'/>",
			        ifFormat	:	Calendar.phpDateFormat("<inp2:{$prefix}_Format field='{$field}' input_format='1'/>"),
			        button		:	"cal_img_<inp2:{$prefix}_InputName field='{$field}'/>",
			        align		:	"br",
			        singleClick	:	true,
			        showsTime	:	true,
			        weekNumbers	:	false,
			        firstDay	:	<inp2:m_GetConfig var="FirstDayOfWeek"/>,
			        onUpdate	:	function(cal) {
			        	document.getElementById('<inp2:{$prefix}_InputName field="{$field}_date"/>').value = cal.date.print( Calendar.phpDateFormat("<inp2:{$prefix}_Format field="{$field}_date" input_format="1"/>") );
			        	document.getElementById('<inp2:{$prefix}_InputName field="{$field}_time"/>').value = cal.date.print( Calendar.phpDateFormat("<inp2:{$prefix}_Format field="{$field}_time" input_format="1"/>") );
			       	}
				});
			</script>
			&nbsp;<input type="text" name="<inp2:{$prefix}_InputName field='{$field}_time'/>" id="<inp2:{$prefix}_InputName field='{$field}_time'/>" value="<inp2:{$prefix}_Field field='{$field}_time' format='_input_'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:{$prefix}_Format field='{$field}_time' input_format='1' edit_size='edit_size'/>" class="<inp2:m_param name='class'/>"><span class="small"> (<inp2:{$prefix}_Format field="{$field}_time" input_format="1" human="true"/>)</span>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="textarea_field_caption_element">
	<inp2:m_RenderElement name="default_field_caption_element" pass_params="1"/>

	<br>
	<inp2:m_if check="m_ParamEquals" name="allow_html" value="allow_html">
		<inp2:{$prefix}_InputName field="$field" result_to_var="input_name"/>
		<a href="<inp2:m_Link template='$edit_template' TargetField='$input_name' pass_through='TargetField' pass='m,$prefix'/>" onclick="openSelector('<inp2:m_Param name='prefix' js_escape='1'/>', this.href, '', '800x575'); return false;">
			<img src="img/icons/icon24_link_editor.gif" border="0">
		</a>
	</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_textarea" caption_render_as="textarea_field_caption_element" class="" format="" edit_template="popups/editor" allow_html="allow_html" style="text-align: left; width: 100%; height: 100px;" control_options="false" row_style="height: auto">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<textarea style="<inp2:m_Param name='style'/>" tabindex="<inp2:m_get param='tab_index'/>" id="<inp2:{$prefix}_InputName field='$field'/>" name="<inp2:{$prefix}_InputName field='$field'/>" ><inp2:{$prefix}_Field field="$field" format="fck_ready;{$format}"/></textarea>
			<script type="text/javascript">
				Form.addControl('<inp2:{$prefix}_InputName field="$field"/>', <inp2:m_param name="control_options"/>);
			</script>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_fck" class="" maxlength="" bgcolor="" onblur="" format="" size="" onkeyup="" style="" has_caption="0" control_options="false">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell" colspan="3" onmouseover="show_form_error('<inp2:m_Param name='prefix' js_escape='1'/>', '<inp2:m_Param name='field' js_escape='1'/>')" onmouseout="hide_form_error('<inp2:m_Param name='prefix' js_escape='1'/>')">
			<inp2:FCKEditor field="$field" width="100%" bgcolor="$bgcolor" height="200" format="$format" late_load="1"/>
			<script type="text/javascript">
				if (typeof(fields['<inp2:m_Param name="prefix" js_escape="1"/>']) == 'undefined') {
					fields['<inp2:m_Param name="prefix" js_escape="1"/>'] = new Object();
				}
				fields['<inp2:m_Param name="prefix" js_escape="1"/>']['<inp2:m_Param name="field" js_escape="1"/>'] = '<inp2:m_phrase label="$title" js_escape="1"/>'

				Form.addControl('<inp2:$prefix_InputName field="$field"/>___Frame', <inp2:m_param name="control_options"/>);
			</script>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_codepress" style="width: 100%;" language="html" has_caption="0" control_options="false">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell" colspan="3" onmouseover="show_form_error('<inp2:m_Param name='prefix' js_escape='1'/>', '<inp2:m_Param name='field' js_escape='1'/>')" onmouseout="hide_form_error('<inp2:m_Param name='prefix' js_escape='1'/>')">
			<inp2:m_ifnot check="m_Get" name="codepress_included">
				<script type="text/javascript" src="<inp2:m_TemplatesBase/>/themes/codepress/codepress.js"></script>
				<script type="text/javascript">
					CodePress.path = '<inp2:m_TemplatesBase/>/themes/codepress/'; // set path here, because script tags are not found in table cells
				</script>
				<inp2:m_Set codepress_included="1"/>
			</inp2:m_ifnot>
			<textarea id="<inp2:$prefix_InputName field='$field'/>" name="<inp2:$prefix_InputName field='$field'/>" class="codepress <inp2:m_Param name='language'/>" style="<inp2:m_Param name='style'/>"><inp2:$prefix_Field field="$field"/></textarea>

			<script type="text/javascript">
				Application.setHook(
					new Array ('<inp2:m_Param name="prefix" js_escape="1"/>:OnPreSaveAndGoToTab', '<inp2:m_Param name="prefix" js_escape="1"/>:OnPreSaveAndGo', '<inp2:m_Param name="prefix" js_escape="1"/>:OnSave', '<inp2:m_Param name="prefix" js_escape="1"/>:OnCreate', '<inp2:m_Param name="prefix" js_escape="1"/>:OnUpdate'),
					function($event) {
						<inp2:m_Param name="field"/>.toggleEditor(); // enable textarea back to save data
						$event.status = true;
					}
				);
				if (typeof(fields['<inp2:m_Param name="prefix" js_escape="1"/>']) == 'undefined') {
					fields['<inp2:m_Param name="prefix" js_escape="1"/>'] = new Object();
				}
				fields['<inp2:m_Param name="prefix" js_escape="1"/>']['<inp2:m_Param name="field" js_escape="1"/>'] = '<inp2:m_phrase label="$title" js_escape="1"/>'

				Form.addControl('<inp2:$prefix_InputName field="$field"/>', <inp2:m_param name="control_options"/>);
			</script>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>


<inp2:m_DefineElement name="textarea_ml_field_caption_element">
	<inp2:m_RenderElement name="default_field_caption_element" pass_params="1"/>

	<br>
	<inp2:m_if check="m_ParamEquals" name="allow_html" value="allow_html">
		<inp2:{$prefix}_InputName field="$field" result_to_var="input_name"/>
		<a href="<inp2:m_Link template='$edit_template' TargetField='$input_name' pass_through='TargetField' pass='m,$prefix'/>" onclick="openSelector('<inp2:m_Param name='prefix' js_escape='1'/>', this.href, '', '800x575'); return false;">
			<img src="img/icons/icon24_link_editor.gif" style="cursor: hand;" border="0">
		</a>
	</inp2:m_if>

	<a href="javascript:PreSaveAndOpenTranslator('<inp2:m_param name="prefix"/>', '<inp2:m_param name="field"/>', 'popups/translator', 1);" title="<inp2:m_Phrase label='la_Translate'/>"><img src="img/icons/icon24_translate.png" border="0"></a>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_textarea_ml">
	<inp2:m_RenderElement name="inp_edit_textarea" format="no_default" pass_params="true"/>
	<!--##<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<textarea style="<inp2:m_Param name='style'/>" tabindex="<inp2:m_get param='tab_index'/>" id="<inp2:{$prefix}_InputName field='$field'/>" name="<inp2:{$prefix}_InputName field='$field'/>" cols="<inp2:m_param name='cols'/>" rows="<inp2:m_param name='rows'/>" class="<inp2:m_param name='class'/>"><inp2:{$prefix}_Field field="$field" format="fck_ready,{$format}"/></textarea>
			<script type="text/javascript">
				Form.addControl('<inp2:{$prefix}_InputName field="$field"/>', <inp2:m_param name="control_options"/>);
			</script>
		</td>
	</inp2:m_RenderElement>##-->
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_user" class="" size="" old_style="0" onkeyup="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<input type="text" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" class="<inp2:m_param name='class'/>" onkeyup="<inp2:m_Param name='onkeyup'/>">
			<inp2:m_if check="m_ParamEquals" name="old_style" value="1">
				<a href="#" onclick="return OpenUserSelector('','kernel_form','<inp2:{$prefix}_InputName field="$field"/>');">
			<inp2:m_else/>
				<a href="javascript:openSelector('<inp2:m_param name='prefix'/>', '<inp2:m_t t='user_selector' pass='all,$prefix' escape='1'/>', '<inp2:m_param name='field'/>');">
			</inp2:m_if>
          		 <img src="img/icons/icon24_link_user.gif" style="cursor:hand;" border="0">
         	</a>

         	<script type="text/javascript">
	         	function processUserSelector($field, $selector) {
	         		var $field_mask = '<inp2:$prefix_InputName name="#FIELD_NAME#"/>';
					var $user_id = parseInt( $selector.Grids['u'].GetSelected() );

					$( jq('#' + $field_mask.replace('#FIELD_NAME#', '<inp2:m_Param name="field"/>')) ).val( $selector.$user_logins[$user_id] );
				}
         	</script>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_category" class="" size="" old_style="0" onkeyup="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<table cellpadding="0" cellspacing="0">
				<tr>
					<td id="<inp2:{$prefix}_InputName field='$field'/>_path"<inp2:m_ifnot check="Field" name="$field" db="db"> style="display: none;"</inp2:m_ifnot>>
						<inp2:m_DefineElement name="category_caption">
							<inp2:m_ifnot check="m_Param" name="is_first">
								<inp2:m_param name="separator"/>
							</inp2:m_ifnot>
							<inp2:m_param name="cat_name"/>
						</inp2:m_DefineElement>

						<inp2:$prefix_FieldCategoryPath field="$field" separator=" &gt; " render_as="category_caption"/>
						<inp2:m_RenderElement name="inp_edit_hidden" pass_params="1"/>
					</td>
					<td valign="middle">
						<img src="img/spacer.gif" width="3" height="1" alt=""/>
						<a href="javascript:openSelector('<inp2:m_param name='prefix'/>', '<inp2:adm_SelectorLink prefix='$prefix' selection_mode='single' tab_prefixes='none'/>', '<inp2:m_param name='field'/>');">
			          		 <img src="img/icons/icon24_cat.gif" width="24" height="24" border="0"/>
			         	</a>

			         	<a href="#" id="<inp2:{$prefix}_InputName field='$field'/>_disable_link"<inp2:m_ifnot check="Field" name="$field" db="db"> style="display: none;"</inp2:m_ifnot>><inp2:m_Phrase name="la_Text_Disable"/></a>

			         	<script type="text/javascript">
							function CategorySelector() {
							}

							CategorySelector.getField = function ($field) {
								return jq('<inp2:{$prefix}_InputName field="#FIELD_NAME#"/>'.replace('#FIELD_NAME#', $field));
							}

							CategorySelector.disableCategory = function ($field) {
								var $field_id = this.getField($field);

				         		$('#' + $field_id).val('');
				         		$('#' + $field_id + '_path, #' + $field_id + '_disable_link').hide();
							}

			         		$(document).ready(
								function() {
									var $field_id = CategorySelector.getField('<inp2:m_Param name="field" js_escape="1"/>');

									$('#' + $field_id + '_disable_link').click(
										function ($e) {
											CategorySelector.disableCategory('<inp2:m_Param name="field" js_escape="1"/>');

											return false;
										}
									);
								}
							);
					    </script>
					</td>
				</tr>
			</table>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_option_item">
	<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="inp_option_phrase">
	<option value="<inp2:m_param name='key'/>"<inp2:m_param name="selected"/>><inp2:m_phrase label="$option"/></option>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_options" onchange="" has_empty="0" empty_value="" style="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<select tabindex="<inp2:m_get param='tab_index'/>" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" onchange="<inp2:m_Param name='onchange'/>" style="<inp2:m_Param name='style'/>">
				<inp2:m_if check="{$prefix}_FieldOption" field="$field" option="use_phrases">
					<inp2:{$prefix}_PredefinedOptions field="$field" block="inp_option_phrase" selected="selected" has_empty="$has_empty" empty_value="$empty_value"/>
				<inp2:m_else/>
					<inp2:{$prefix}_PredefinedOptions field="$field" block="inp_option_item" selected="selected" has_empty="$has_empty" empty_value="$empty_value"/>
				</inp2:m_if>
			</select>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_multioptions" has_empty="0" empty_value="" style="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<select multiple tabindex="<inp2:m_get param='tab_index'/>" id="<inp2:{$prefix}_InputName field='$field'/>_select" onchange="update_multiple_options('<inp2:{$prefix}_InputName field='$field'/>');">
				<inp2:m_if check="{$prefix}_FieldOption" field="$field" option="use_phrases">
					<inp2:{$prefix}_PredefinedOptions field="$field" block="inp_option_phrase" selected="selected" has_empty="$has_empty" empty_value="$empty_value"/>
				<inp2:m_else/>
					<inp2:{$prefix}_PredefinedOptions field="$field" block="inp_option_item" selected="selected" has_empty="$has_empty" empty_value="$empty_value"/>
				</inp2:m_if>
			</select>
			<input type="hidden" id="<inp2:{$prefix}_InputName field='$field'/>" name="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field' db='db'/>"/>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_radio_item" onclick="" onchange="">
	<input type="radio" <inp2:m_param name="checked"/> name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field="$field"/>_<inp2:m_param name="key"/>" value="<inp2:m_param name="key"/>" onclick="<inp2:m_param name="onclick"/>" onchange="<inp2:m_param name="onchange"/>"><label for="<inp2:{$prefix}_InputName field="$field"/>_<inp2:m_param name="key"/>"><inp2:m_param name="option"/></label>&nbsp;
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_radio_phrase" onclick="" onchange="">
	<input type="radio" <inp2:m_param name="checked"/> name="<inp2:{$prefix}_InputName field="$field"/>" id="<inp2:{$prefix}_InputName field="$field"/>_<inp2:m_param name="key"/>" value="<inp2:m_param name="key"/>" onclick="<inp2:m_param name="onclick"/>" onchange="<inp2:m_param name="onchange"/>"><label for="<inp2:{$prefix}_InputName field="$field"/>_<inp2:m_param name="key"/>"><inp2:m_phrase label="$option"/></label>&nbsp;
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_radio" pass_tabindex="" onclick="" onchange="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<inp2:m_if check="{$prefix}_FieldOption" field="$field" option="use_phrases">
				<inp2:{$prefix}_PredefinedOptions field="$field" tabindex="$pass_tabindex" block="inp_radio_phrase" selected="checked" onclick="$onclick" onchange="$onchange" />
			<inp2:m_else />
				<inp2:{$prefix}_PredefinedOptions field="$field" tabindex="$pass_tabindex" block="inp_radio_item" selected="checked" onclick="$onclick" onchange="$onchange" />
			</inp2:m_if>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="js_option_item">
	'<inp2:m_Param name="key" js_escape="1"/>': '<inp2:m_Param name="option" js_escape="1"/>'<inp2:m_ifnot check="m_Param" name="is_last">, </inp2:m_ifnot>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="js_option_phrase">
	'<inp2:m_Param name="key" js_escape="1"/>': '<inp2:m_Phrase name="$option" js_escape="1"/>'<inp2:m_ifnot check="m_Param" name="is_last">, </inp2:m_ifnot>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_json_options">
	<inp2:m_if check="{$prefix}_FieldOption" field="$field" option="use_phrases">
		{<inp2:{$prefix}_PredefinedOptions field="$field" block="js_option_phrase" selected="selected"/>}
	<inp2:m_else />
		{<inp2:{$prefix}_PredefinedOptions field="$field" block="js_option_item" selected="selected"/>}
	</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_checkbox" field_class="" onchange="" onclick="" NamePrefix="_cb_">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<input type="hidden" id="<inp2:{$prefix}_InputName field='$field'/>" name="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field' db='db'/>">
			<!--<input tabindex="<inp2:m_get param='tab_index'/>" type="checkbox" id="_cb_<inp2:{$prefix}_InputName field='$field'/>" name="_cb_<inp2:{$prefix}_InputName field='$field'/>" <inp2:{$prefix}_Field field="$field" checked="checked" db="db"/> class="<inp2:m_param name='field_class'/>" onclick="update_checkbox(this, document.getElementById('<inp2:{$prefix}_InputName field='$field'/>'));" onchange="<inp2:m_param name='onchange'/>">-->
			<input tabindex="<inp2:m_get param='tab_index'/>" type="checkbox" id="_cb_<inp2:{$prefix}_InputName field='$field'/>" name="_cb_<inp2:{$prefix}_InputName field='$field'/>" <inp2:{$prefix}_Field field="$field" checked="checked" db="db"/> class="<inp2:m_param name='field_class'/>" onchange="update_checkbox(this, document.getElementById('<inp2:{$prefix}_InputName field='$field'/>'));<inp2:m_param name='onchange'/>" onclick="<inp2:m_param name='onclick'/>">
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_checkbox_item">
	<input type="checkbox" <inp2:m_param name='checked'/> id="<inp2:{$prefix}_InputName field='$field'/>_<inp2:m_param name='key'/>" value="<inp2:m_param name='key'/>" onclick="update_checkbox_options(/^<inp2:{$prefix}_InputName field='$field' as_preg='1'/>_([0-9A-Za-z-]+)/, '<inp2:{$prefix}_InputName field='$field'/>');"><label for="<inp2:{$prefix}_InputName field='$field'/>_<inp2:m_param name='key'/>"><inp2:m_param name="option"/></label><inp2:m_if check="m_Param" name="has_br"><br/><inp2:m_else/>&nbsp;</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_checkbox_phrase">
	<input type="checkbox" <inp2:m_param name='checked'/> id="<inp2:{$prefix}_InputName field='$field'/>_<inp2:m_param name='key'/>" value="<inp2:m_param name='key'/>" onclick="update_checkbox_options(/^<inp2:{$prefix}_InputName field='$field' as_preg='1'/>_([0-9A-Za-z-]+)/, '<inp2:{$prefix}_InputName field='$field'/>');"><label for="<inp2:{$prefix}_InputName field='$field'/>_<inp2:m_param name='key'/>"><inp2:m_phrase label="$option"/></label><inp2:m_if check="m_Param" name="has_br"><br/><inp2:m_else/>&nbsp;</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_checkboxes" no_empty="" pass_tabindex="" has_br="0">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<inp2:m_if check="{$prefix}_FieldOption" field="$field" option="use_phrases">
				<inp2:{$prefix}_PredefinedOptions field="$field" no_empty="$no_empty" tabindex="$pass_tabindex" block="inp_checkbox_phrase" selected="checked" has_br="$has_br"/>
			<inp2:m_else/>
				<inp2:{$prefix}_PredefinedOptions field="$field" no_empty="$no_empty" tabindex="$pass_tabindex" block="inp_checkbox_item" selected="checked" has_br="$has_br"/>
			</inp2:m_if>
			<inp2:m_RenderElement prefix="$prefix" name="inp_edit_hidden" field="$field" db="db"/>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_checkbox_allow_html" field_class="" onchange="" onclick="" title="la_enable_html" hint_label="la_Warning_Enable_HTML">
	<inp2:m_RenderElement name="inp_edit_checkbox" pass_params="1"/>

	<!--##
	<inp2:m_if check="{$prefix}_FieldVisible" field="$field">
		<tr class="<inp2:m_odd_even odd='edit-form-odd' even='edit-form-even'/>" id="<inp2:$prefix_InputName field='$field'/>_row">
			<td class="control-cell">
				<input type="hidden" id="<inp2:{$prefix}_InputName field='$field'/>" name="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field' db='db'/>">
				<input tabindex="<inp2:m_get param='tab_index'/>" type="checkbox" id="_cb_<inp2:{$prefix}_InputName field='$field'/>" name="_cb_<inp2:{$prefix}_InputName field='$field'/>" <inp2:{$prefix}_Field field="$field" checked="checked" db="db"/> class="<inp2:m_param name='field_class'/>" onchange="update_checkbox(this, document.getElementById('<inp2:{$prefix}_InputName field='$field'/>'));<inp2:m_param name='onchange'/>" onclick="<inp2:m_param name='onclick'/>">
			</td>
			<inp2:m_RenderElement name="inp_edit_error" pass_params="1"/>
		</tr>
	</inp2:m_if>
	##-->
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_weight" class="" size="" maxlength="" onblur="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<inp2:m_if check="lang.current_FieldEquals" field="UnitSystem" value="1">
				<input type="text" name="<inp2:{$prefix}_InputName field='$field'/>" id="<inp2:{$prefix}_InputName field='$field'/>" value="<inp2:{$prefix}_Field field='$field'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" maxlength="<inp2:m_param name='maxlength'/>" class="<inp2:m_param name='class'/>" onblur="<inp2:m_Param name='onblur'/>">
				<inp2:m_phrase label="la_kg" />
			</inp2:m_if>
			<inp2:m_if check="lang.current_FieldEquals" field="UnitSystem" value="2">
				<input type="text" name="<inp2:{$prefix}_InputName field='{$field}_a'/>" id="<inp2:{$prefix}_InputName field='{$field}_a'/>" value="<inp2:{$prefix}_Field field='{$field}_a'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" maxlength="<inp2:m_param name='maxlength'/>" class="<inp2:m_param name='class'/>" onblur="<inp2:m_Param name='onblur'/>">
				<inp2:m_phrase label="la_lbs" />
				<input type="text" name="<inp2:{$prefix}_InputName field='{$field}_b'/>" id="<inp2:{$prefix}_InputName field='{$field}_b'/>" value="<inp2:{$prefix}_Field field='{$field}_b'/>" tabindex="<inp2:m_get param='tab_index'/>" size="<inp2:m_param name='size'/>" maxlength="<inp2:m_param name='maxlength'/>" class="<inp2:m_param name='class'/>" onblur="<inp2:m_Param name='onblur'/>">
				<inp2:m_phrase label="la_oz" />
			</inp2:m_if>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_minput" style="" format="" allow_add="1" allow_edit="1" allow_delete="1" allow_move="1" title="">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<table>
				<tr>
					<td colspan="2">
						<input type="button" class="button" style="width: 70px;" value="<inp2:m_Phrase name='la_btn_Add'/>" id="<inp2:$prefix_InputName field='$field'/>_add_button"/>
						<input type="button" class="button" style="width: 70px;" value="<inp2:m_Phrase name='la_btn_Cancel'/>" id="<inp2:$prefix_InputName field='$field'/>_cancel_button"/>
					</td>
				</tr>
				<tr>
					<td valign="top">
						<select multiple tabindex="<inp2:m_get param='tab_index'/>" id="<inp2:$prefix_InputName field='$field'/>_minput" style="<inp2:m_Param name='style'/>">
						</select>
					</td>
					<td valign="top">
						<inp2:m_if check="m_Param" name="allow_edit">
							<input type="button" class="button" style="width: 100px;" value="<inp2:m_Phrase name='la_btn_Edit'/>" id="<inp2:$prefix_InputName field='$field'/>_edit_button"/><br />
							<img src="img/spacer.gif" height="4" width="1" alt=""/><br />
						</inp2:m_if>

						<inp2:m_if check="m_Param" name="allow_delete">
							<input type="button" class="button" style="width: 100px;" value="<inp2:m_Phrase name='la_btn_Delete'/>" id="<inp2:$prefix_InputName field='$field'/>_delete_button"/><br />
						</inp2:m_if>

						<inp2:m_if check="m_Param" name="allow_move">
							<br /><br />
							<input type="button" class="button" style="width: 100px;" value="<inp2:m_Phrase name='la_btn_MoveUp'/>" id="<inp2:$prefix_InputName field='$field'/>_moveup_button"/><br />
						<img src="img/spacer.gif" height="4" width="1" alt=""/><br />
							<input type="button" class="button" style="width: 100px;" value="<inp2:m_Phrase name='la_btn_MoveDown'/>" id="<inp2:$prefix_InputName field='$field'/>_movedown_button"/><br />
						</inp2:m_if>
					</td>
				</tr>
				<inp2:m_RenderElement name="inp_edit_hidden" prefix="$prefix" field="$field" db="db"/>
				<script type="text/javascript">
					var <inp2:m_Param name="field"/> = new MultiInputControl('<inp2:m_Param name="field"/>', '<inp2:{$prefix}_InputName field="#FIELD_NAME#"/>', fields['<inp2:m_Param name="prefix"/>'], '<inp2:m_Param name="format"/>');
					<inp2:m_Param name="field"/>.ValidateURL = '<inp2:m_Link template="dummy" pass="m,$prefix" {$prefix}_event="OnValidateMInputFields" js_escape="1"/>';
					<inp2:m_if check="m_Param" name="allow_add">
						<inp2:m_Param name="field"/>.SetPermission('add', true);
					</inp2:m_if>
					<inp2:m_if check="m_Param" name="allow_edit">
						<inp2:m_Param name="field"/>.SetPermission('edit', true);
					</inp2:m_if>
					<inp2:m_if check="m_Param" name="allow_delete">
						<inp2:m_Param name="field"/>.SetPermission('delete', true);
					</inp2:m_if>
					<inp2:m_if check="m_Param" name="allow_move">
						<inp2:m_Param name="field"/>.SetPermission('move', true);
					</inp2:m_if>
					<inp2:m_Param name="field"/>.InitEvents();

					<inp2:m_Param name="field"/>.SetMessage('required_error', '<inp2:m_Phrase name="la_err_required" escape="1"/>');
					<inp2:m_Param name="field"/>.SetMessage('unique_error', '<inp2:m_Phrase name="la_error_unique" escape="1"/>');
					<inp2:m_Param name="field"/>.SetMessage('delete_confirm', '<inp2:m_Phrase label="la_Delete_Confirm" escape="1"/>');
					<inp2:m_Param name="field"/>.SetMessage('add_button', '<inp2:m_Phrase name="la_btn_Add" escape="1"/>');
					<inp2:m_Param name="field"/>.SetMessage('save_button', '<inp2:m_Phrase name="la_btn_Save" escape="1"/>');
				</script>
			</table>
		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_picker" has_empty="0" empty_value="" style="width: 225px;" size="15">
	<inp2:m_RenderElement design="form_row" pass_params="1">
		<td class="control-cell">
			<table cellpadding="0" cellspacing="0">
				<tr>
					<td><strong><inp2:m_Phrase label="la_SelectedItems" /></strong></td>
					<td>&nbsp;</td>
					<td><strong><inp2:m_Phrase label="la_AvailableItems" /></strong></td>
				</tr>
				<tr>
					<td>
						<inp2:m_DefineElement name="picker_option_block">
							<option value="<inp2:Field name='$key_field' />"><inp2:Field name="$value_field" /></option>
						</inp2:m_DefineElement>

						<select multiple id="<inp2:$prefix_InputName name='$field' />_selected" style="<inp2:m_param name='style'/>" size="<inp2:m_param name='size'/>">
							<inp2:$optprefix.selected_PrintList render_as="picker_option_block" key_field="$option_key_field" value_field="$option_value_field" per_page="-1" requery="1" link_to_prefix="$prefix" link_to_field="$field"/>
						</select>
					</td>
					<td align="center">
						<img src="img/icons/icon_left.gif" id="<inp2:$prefix_InputName name="$field" />_move_left_button"/><br />
						<img src="img/icons/icon_right.gif" id="<inp2:$prefix_InputName name="$field" />_move_right_button"/>
					</td>
					<td>
						<select multiple id="<inp2:$prefix_InputName name='$field' />_available" style="<inp2:m_param name='style'/>" size="<inp2:m_param name='size'/>">
							<inp2:$optprefix.available_PrintList render_as="picker_option_block" key_field="$option_key_field" value_field="$option_value_field" requery="1" per_page="-1" link_to_prefix="$prefix" link_to_field="$field"/>
						</select>
					</td>
				</tr>
			</table>

			<input type="hidden" name="<inp2:$prefix_InputName name='$field' />" id="<inp2:$prefix_InputName name='$field' />" value="<inp2:$prefix_Field field='$field' db='db'/>">
			<input type="hidden" name="unselected_<inp2:$prefix_InputName name='$field' />" id="<inp2:$prefix_InputName name='$field' />_available_field" value="">

			<script type="text/javascript">
				<inp2:m_Param name="field"/> = new EditPickerControl('<inp2:m_Param name="field"/>', '<inp2:$prefix_InputName name="$field" />');
				<inp2:m_Param name="field"/>.SetMessage('nothing_selected', '<inp2:m_Phrase label="la_error_SelectItemToMove" escape="1"/>');
			</script>

		</td>
	</inp2:m_RenderElement>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="inp_edit_filler" control_options="false">
	<tr class="<inp2:m_odd_even odd='edit-form-odd' even='edit-form-even'/>" style="height: auto">
		<td class="label-cell-filler" ></td>
		<td class="control-mid-filler" ></td>
		<td class="control-cell-filler">
			<input type="text" style="display: none;"/>
			<div id="form_filler" style="width: 100%; height: 5px; background-color: inherit"></div>
			<script type="text/javascript">
				Form.addControl('form_filler', <inp2:m_param name="control_options"/>);
			</script>
		</td>
	</tr>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="ajax_progress_bar">
	<table width="100%" border="0" cellspacing="0" cellpadding="2" class="tableborder">
		<tr class="<inp2:m_odd_even odd='table-color1' even='table-color2'/>">
			<td colspan="2">
				<img src="img/spacer.gif" height="10" width="1" alt="" /><br />
				<!-- progress bar paddings: begin -->
				<table width="90%" cellpadding="2" cellspacing="0" border="0" align="center">
					<tr>
						<td class="progress-text">0%</td>
						<td width="100%">
							<!-- progress bar: begin -->
							<table cellspacing="0" cellpadding="0" width="100%" border="0" align="center" style="background-color: #FFFFFF; border: 1px solid #E6E6E6;">
								<tr>
									<td colspan="3"><img src="img/spacer.gif" height="2" width="1" alt="" /></td>
								</tr>
								<tr>
									<td width="2"><img src="img/spacer.gif" height="13" width="3" alt="" /></td>
									<td align="center" width="100%">
										<table cellspacing="0" cellpadding="0" width="100%" border="0" style="background: url(img/progress_left.gif) repeat-x;">
											<tr>
												<td id="progress_bar[done]" style="background: url(img/progress_done.gif);" align="left"></td>
												<td id="progress_bar[left]" align="right"><img src="img/spacer.gif" height="9" width="1" alt="" /></td>
											</tr>
										</table>
									</td>
									<td width="1"><img src="img/spacer.gif" height="13" width="3" alt="" /></td>
								</tr>
								<tr>
									<td colspan="3"><img src="img/spacer.gif" height="2" width="1" alt="" /></td>
								</tr>
							</table>
							<!-- progress bar: end -->
						</td>
						<td class="progress-text">100%</td>
					</tr>
				</table>
				<!-- progress bar paddings: end -->
				<img src="img/spacer.gif" height="10" width="1" alt="" /><br />
			</td>
		</tr>
		<tr class="<inp2:m_odd_even odd='table-color1' even='table-color2'/>">
			<td width="50%" align="right"><inp2:m_phrase name="la_fld_PercentsCompleted"/>:</td>
			<td id="progress_display[percents_completed]">0%</td>
		</tr>
		<tr class="<inp2:m_odd_even odd='table-color1' even='table-color2'/>">
			<td align="right"><inp2:m_phrase name="la_fld_ElapsedTime"/>:</td>
			<td id="progress_display[elapsed_time]">00:00</td>
		</tr>
		<tr class="<inp2:m_odd_even odd='table-color1' even='table-color2'/>">
			<td align="right"><inp2:m_phrase name="la_fld_EstimatedTime"/>:</td>
			<td id="progress_display[Estimated_time]">00:00</td>
		</tr>
		<tr class="<inp2:m_odd_even odd='table-color1' even='table-color2'/>">
			<td align="center" colspan="2">
				<input type="button" class="button" onclick="<inp2:m_param name="cancel_action"/>" value="<inp2:m_phrase name="la_Cancel"/>" />
			</td>
		</tr>
	</table>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="edit_navigation" toolbar="a_toolbar">
	<inp2:m_if check="{$prefix}_IsTopmostPrefix">
		<inp2:m_if check="{$prefix}_IsSingle">
			<inp2:m_param name="toolbar"/>.HideButton('prev');
			<inp2:m_param name="toolbar"/>.HideButton('next');
		<inp2:m_else/>
			<inp2:m_if check="{$prefix}_IsLast">
				<inp2:m_param name="toolbar"/>.DisableButton('next');
			</inp2:m_if>
			<inp2:m_if check="{$prefix}_IsFirst">
				<inp2:m_param name="toolbar"/>.DisableButton('prev');
			</inp2:m_if>
		</inp2:m_if>
	</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="tabs_container" tabs_render_as="">
	<table cellpadding="0" cellspacing="0" style="width: 100%;">
		<tr>
			<td style="width: 20px;">
				<img src="<inp2:m_TemplatesBase/>/img/spacer.gif" width="20" height="0" alt=""/><br/>
				<a href="#" class="scroll-left disabled"></a>
			</td>

			<td height="23" align="right">
				<div id="tab-measure" style="display: none; width: 100%; height: 23px;">&nbsp;</div>
				<div style="overflow: hidden; height: 23px;" class="tab-viewport">
					<table class="tabs" cellpadding="0" cellspacing="0" height="23">
						<tr>
							<inp2:m_RenderElement name="$tabs_render_as" pass_params="1"/>
						</tr>
					</table>
				</div>
			</td>

			<td class="scroll-right-container disabled">
				<img src="<inp2:m_TemplatesBase/>/img/spacer.gif" width="20" height="0" alt=""/><br/>
				<a href="#" class="scroll-right disabled"></a>
			</td>
		</tr>
	</table>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="edit_tabs_element">
	<inp2:m_DefineElement name="edit_tab">
		<inp2:m_RenderElement name="tab" title="$title" t="$template" main_prefix="$PrefixSpecial"/>
	</inp2:m_DefineElement>

	<inp2:{$prefix}_PrintEditTabs render_as="edit_tab" preset_name="$preset_name"/>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="edit_tabs" preset_name="Default">
	<inp2:m_if check="{$prefix}_HasEditTabs" preset_name="$preset_name">
		<inp2:m_RenderElement name="tabs_container" tabs_render_as="edit_tabs_element" pass_params="1"/>
	</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="ml_selector" prefix="">
	<inp2:m_if check="lang_IsMultiLanguage">
		<td align="right" style="padding-right: 5px;">
			<table width="100%" cellpadding="0" cellspacing="0">
				<tr>
					<td align="right">
						<inp2:m_phrase name="la_fld_Language"/>:
						<select name="language" onchange="submit_event('<inp2:m_param name='prefix'/>', 'OnPreSaveAndChangeLanguage');">
							<inp2:m_DefineElement name="lang_elem">
								<option value="<inp2:Field name='LanguageId'/>" <inp2:m_if check="SelectedLanguage" type="data">selected="selected"</inp2:m_if> ><inp2:Field name="LocalName" no_special='no_special' /></option>
							</inp2:m_DefineElement>
							<inp2:lang_PrintList render_as="lang_elem"/>
						</select>
					</td>
				</tr>
				<tr>
					<td align="right" style="vertical-align: bottom; padding: 2px 0px 5px 2px;">
						<span style="color: red">*</span>&nbsp;<span class="req-note"><inp2:m_Phrase name="la_text_RequiredFields"/></span>
					</td>
				</tr>
			</table>
		</td>
	<inp2:m_else/>
		<td align="right" style="vertical-align: bottom; padding: 2px 5px 5px 2px;">
			<span style="color: red">*</span>&nbsp;<span class="req-note"><inp2:m_Phrase name="la_text_RequiredFields"/></span>
		</td>
	</inp2:m_if>
</inp2:m_DefineElement>

<inp2:m_DefineElement name="form_error_warning">
	<inp2:m_RenderElement design="form_message" pass_params="1">
		<inp2:m_Phrase name="la_Warning_NewFormError"/><br/>
		<span id="error_msg_<inp2:m_Param name='prefix'/>" style="font-weight: bold;"><br/></span>
    </inp2:m_RenderElement>
</inp2:m_DefineElement>
