Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Dev : use flash message rather than controller error
- Loading branch information
LouisGac
committed
Nov 27, 2015
1 parent
bee9b84
commit c0da7df
Showing
2 changed files
with
74 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,19 @@ | ||
<div class='header ui-widget-header'><?php eT("Uploaded template file") ?></div> | ||
<?php echo CHtml::form(array('admin/templates/sa/upload'), 'post', array('id'=>'importtemplate', 'name'=>'importtemplate', 'enctype'=>'multipart/form-data', 'onsubmit'=>'return validatefilename(this,"'.gT('Please select a file to import!', 'js').'");')); ?> | ||
|
||
<input type='hidden' name='lid' value='$lid' /> | ||
<input type='hidden' name='action' value='templateupload' /> | ||
<ul> | ||
<li> | ||
<label for='the_file'><?php eT("Select template ZIP file:") ?></label> | ||
<input id='the_file' name='the_file' type="file" /> | ||
</li> | ||
<li> | ||
<label> </label> | ||
<?php if (!function_exists("zip_open")) {?> | ||
<?php eT("zip library not supported by PHP, Import ZIP Disabled", "js") ?> | ||
<?php } else {?> | ||
<input type='button' value='<?php eT("Import template ZIP archive") ?>' onclick='if (validatefilename(this.form,"<?php eT('Please select a file to import!', 'js') ?>")) { this.form.submit();}' /> | ||
<?php }?> | ||
</li> | ||
</ul> | ||
</form> | ||
<h3 class="pagetitle"><?php eT("Uploaded template file") ?></h3> | ||
<?php echo CHtml::form(array('admin/templates/sa/upload'), 'post', array('id'=>'importtemplate', 'name'=>'importtemplate', 'enctype'=>'multipart/form-data', 'onsubmit'=>'return validatefilename(this,"'.gT('Please select a file to import!', 'js').'");')); ?> | ||
<input type='hidden' name='lid' value='$lid' /> | ||
<input type='hidden' name='action' value='templateupload' /> | ||
<div class="form-group"> | ||
<label for='the_file'><?php eT("Select template ZIP file:") ?></label> | ||
<input id='the_file' name='the_file' type="file" /> | ||
</div> | ||
<div class="form-group"> | ||
|
||
<?php if (!function_exists("zip_open")) {?> | ||
<?php eT("zip library not supported by PHP, Import ZIP Disabled", "js") ?> | ||
<?php } else {?> | ||
<input class="btn btn-default" type='button' value='<?php eT("Import template ZIP archive") ?>' onclick='if (validatefilename(this.form,"<?php eT('Please select a file to import!', 'js') ?>")) { this.form.submit();}' /> | ||
<?php }?> | ||
</div> | ||
|
||
</form> |