Файл: adultscript-2.0.3-pro/files/admin/templates/default/language_install.tpl.php
Строк: 111
<?php defined('_VALID') or die('Restricted Access!'); ?>
<?php echo $this->fetch('errors'); ?>
<?php echo $this->fetch('messages'); ?>
<?php echo $this->fetch('warnings'); ?>
<script type="text/javascript">
$(document).ready(function() {
$("select[name='method']").change(function() {
var method = $(this).val();
$("fieldset[id^='method-']").hide();
$("fieldset[id='method-" + method + "']").show();
});
});
</script>
<div id="container" class="clearfix">
<div id="page">
<?php echo $this->fetch('main_menu'); ?>
<div class="content clearfix">
<?php echo $this->fetch('language_menu'); ?>
<?php if ($this->lang): ?>
<form id="language-install-form" method="post" enctype="multipart/form-data" action="<?php echo ADMIN_URL; ?>/index.php?q=language/install">
<fieldset>
<legend>Install Method</legend>
<div class="required">
<label for="method">Method:</label>
<select name="method" id="method">
<option value="clone"<?php if ($this->method == 'clone'): echo ' selected="selected"'; endif; ?>>Clone Existing Language</option>
<option value="xml"<?php if ($this->method == 'xml'): echo ' selected="selected"'; endif; ?>>From Exported XML</option>
</select>
</div>
</fieldset>
<fieldset id="method-clone" <?php if ($this->method != 'clone'): echo ' style="display: none;"'; endif; ?>>
<legend>Language Information</legend>
<div class="required">
<label for="clone">Language:</label>
<select name="clone" id="clone">
<?php foreach ($this->languages as $language): ?>
<option value="<?php echo e($language['code']); ?>"<?php if ($this->lang['clone'] == $language['code']): echo ' selected="selected"'; endif; ?>><?php echo e($language['name']); ?></option>
<?php endforeach; ?>
</select>
</div>
<div class="required">
<label for="code">CODE:</label>
<input name="code" type="text" id="code" class="small" value="<?php echo e($this->lang['code']); ?>" />
</div>
<div class="required">
<label for="name">Name:</label>
<input name="name" type="text" id="name" class="large" value="<?php echo e($this->lang['name']); ?>" />
</div>
<div class="required">
<label for="flag">Flag:</label>
<input name="flag" type="text" id="flag" class="small" value="<?php echo e($this->lang['flag']); ?>" />
</div>
<div class="optional">
<label for="status">Status:</label>
<input name="status" type="radio" id="status" class="radio" value="1"<?php if ($this->lang['status'] == '1'): echo ' checked="checked"'; endif; ?> /> Active
<input name="status" type="radio" class="radio" value="0"<?php if ($this->lang['status'] == '0'): echo ' checked="checked"'; endif; ?> /> Disabled
</div>
</fieldset>
<fieldset id="method-xml" <?php if ($this->method != 'xml'): echo ' style="display: none;"'; endif; ?>>
<legend>Export XML Upload</legend>
<div class="required">
<label for="file_xml">File:</label>
<input name="file_xml" id="file_xml" type="file" />
</div>
</fieldset>
<div class="submit">
<input name="submit-install" type="submit" id="submit-install" class="button butDef" value=" Install " />
</div>
</form>
<?php else: ?>
<div class="none">Invalid language! Are you sure this language exists!?</div>
<?php endif; ?>
</div>
</div>
</div>