Newer
Older
<div class='page-header'>
<h1><tmpl_var name="list_head_txt"></h1>
</div>
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
<p><tmpl_var name="list_desc_txt"></p>
<div class="form-group">
<label for="name" class="col-sm-3 control-label">{tmpl_var name='name_txt'}</label>
<div class="col-sm-9"><input type="text" name="name" id="name" value="{tmpl_var name='name'}" class="form-control" /></div></div>
<div class="form-group">
<label for="type" class="col-sm-3 control-label">{tmpl_var name='type_txt'}</label>
<div class="col-sm-9"><select name="type" id="type" class="form-control">
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
{tmpl_var name='type'}
</select>
</div></div>
<div class="form-group">
<label for="snippet" class="col-sm-3 control-label">{tmpl_var name='snippet_txt'}</label>
<div class="col-sm-9"><textarea class="form-control" name="snippet" id="snippet" rows='10' cols='50' style="width:400px;">{tmpl_var name='snippet'}</textarea></div><span class="nginx"> {tmpl_var name='variables_txt'}: </span><a href="javascript:void(0);" class="addPlaceholder nginx">{DOCROOT}</a><span class="nginx">, </span><a href="javascript:void(0);" class="addPlaceholder nginx">{FASTCGIPASS}</a>
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
</div>
<div class="form-group">
<label class="col-sm-3 control-label">{tmpl_var name='customer_viewable_txt'}</label>
<div class="col-sm-9">
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
{tmpl_var name='customer_viewable'}
</div>
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
</div>
<div class="form-group">
<label class="col-sm-3 control-label">{tmpl_var name='active_txt'}</label>
<div class="col-sm-9">
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
{tmpl_var name='active'}
</div>
</div>
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
<input type="hidden" name="id" value="{tmpl_var name='id'}">
<div class="clear"><div class="right">
<button class="btn btn-default formbutton-success" type="button" value="{tmpl_var name='btn_save_txt'}" onclick="submitForm('pageForm','admin/directive_snippets_edit.php');">{tmpl_var name='btn_save_txt'}</button>
<button class="btn btn-default formbutton-default" type="button" value="{tmpl_var name='btn_cancel_txt'}" data-load-content="admin/directive_snippets_list.php">{tmpl_var name='btn_cancel_txt'}</button>
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
<script language="JavaScript" type="text/javascript">
if(jQuery('#type').val() == 'nginx'){
jQuery('.nginx:hidden').show();
} else {
jQuery('.nginx:visible').hide();
}
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
if (jQuery('#type').val() != 'nginx' && jQuery('#type').val() != 'apache') {
jQuery('#customer_viewable').closest('div.ctrlHolder:visible').hide();
}else {
jQuery('#customer_viewable').closest('div.ctrlHolder:hidden').show();
}
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
jQuery('#type').change(function(){
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
if (jQuery(this).val() != 'nginx' && jQuery(this).val() != 'apache') {
jQuery('#customer_viewable').closest('div.ctrlHolder:visible').hide();
} else {
jQuery('#customer_viewable').closest('div.ctrlHolder:hidden').show();
}
![Falko Timme Falko Timme's avatar](/uploads/-/system/user/avatar/3/avatar.png?width=72)
Falko Timme
committed
if(jQuery(this).val() == 'nginx'){
jQuery('.nginx:hidden').show();
} else {
jQuery('.nginx:visible').hide();
}
});
</script>