File "181db3afc52ca0a227eb5bdda916ef842f83540a_0.file.admin-images.tmpl.php"

Full Path: /srv/www/www.cadoro.it/src/templates_c/181db3afc52ca0a227eb5bdda916ef842f83540a_0.file.admin-images.tmpl.php
File size: 4.72 KB
MIME-type: text/x-php
Charset: utf-8

<?php
/* Smarty version 3.1.29, created on 2024-03-01 14:39:57
  from "/srv/www/www.cadoro.it/src/templates/admin-images.tmpl" */

if ($_smarty_tpl->smarty->ext->_validateCompiled->decodeProperties($_smarty_tpl, array (
  'has_nocache_code' => false,
  'version' => '3.1.29',
  'unifunc' => 'content_65e1daadcc6598_60746456',
  'file_dependency' => 
  array (
    '181db3afc52ca0a227eb5bdda916ef842f83540a' => 
    array (
      0 => '/srv/www/www.cadoro.it/src/templates/admin-images.tmpl',
      1 => 1708527642,
      2 => 'file',
    ),
  ),
  'includes' => 
  array (
  ),
),false)) {
function content_65e1daadcc6598_60746456 ($_smarty_tpl) {
?>
<table class="table table-striped mt20"<?php if (!$_smarty_tpl->tpl_vars['images']->value) {?> style="display: none"<?php }?>>
  <tbody>
    <?php
$_from = $_smarty_tpl->tpl_vars['images']->value;
if (!is_array($_from) && !is_object($_from)) {
settype($_from, 'array');
}
$__foreach_image_0_saved_item = isset($_smarty_tpl->tpl_vars['image']) ? $_smarty_tpl->tpl_vars['image'] : false;
$_smarty_tpl->tpl_vars['image'] = new Smarty_Variable();
$_smarty_tpl->tpl_vars['image']->_loop = false;
foreach ($_from as $_smarty_tpl->tpl_vars['image']->value) {
$_smarty_tpl->tpl_vars['image']->_loop = true;
$__foreach_image_0_saved_local_item = $_smarty_tpl->tpl_vars['image'];
?>
    <tr>
      <td width="45%">
        <a href="" class="handle"><i class="glyphicon glyphicon-move"></i></a>
        <a href="<?php echo $_smarty_tpl->tpl_vars['base_url']->value;?>
/assets/<?php echo $_smarty_tpl->tpl_vars['image']->value['asset'];?>
" rel="gallery">
          <?php echo $_smarty_tpl->tpl_vars['image']->value['name'];?>

        </a>
        <input type="text" class="form-control mt10 mb10" name="images_title[]" value="<?php echo _a($_smarty_tpl->tpl_vars['image']->value,'title');?>
" placeholder="Titolo">
        <input type="hidden" name="images_aviary[]" value="">
        <img src="<?php echo $_smarty_tpl->tpl_vars['base_url']->value;?>
/assets/<?php echo $_smarty_tpl->tpl_vars['image']->value['asset'];?>
" class="img-editable img-editable-noremove img-responsive" id="gallery-<?php echo $_smarty_tpl->tpl_vars['i']->value+1;?>
" style="max-width: 240px;">
      </td>
      <td width="15%" class="text-right">
        <input type="hidden" name="images[]" value="<?php echo htmlentities(json_encode($_smarty_tpl->tpl_vars['image']->value));?>
">
        <?php echo round($_smarty_tpl->tpl_vars['image']->value['size']/1024);?>
 kb
      </td>
      <td width="20%">
        -
      </td>
      <td width="20%" class="text-right">
        <a href="#" class="btn btn-default btn-xs btn-danger" data-behaviour="fileupload-remove">
          <i class="glyphicon-remove glyphicon"></i> Rimuovi
        </a>
      </td>
    </tr>
    <?php
$_smarty_tpl->tpl_vars['image'] = $__foreach_image_0_saved_local_item;
}
if ($__foreach_image_0_saved_item) {
$_smarty_tpl->tpl_vars['image'] = $__foreach_image_0_saved_item;
}
?>
  </tbody>
</table>
<?php echo '<script'; ?>
 type="text/html">
  <tr>
    <td width="45%">
      <a href="" class="handle"><i class="glyphicon glyphicon-move"></i></a> <?php echo '<%';?>= file.name <?php echo '%>';?>
      <input type="text" class="form-control mt10" name="images_title[]" value="" placeholder="Titolo">
    </td>
    <td width="15%" class="text-right">
      <?php echo '<%';?>= Math.round(file.size / 1024) || 1 <?php echo '%>';?> kb
    </td>
    <td width="20%">
      <?php echo '<%';?> if (status == 0) { <?php echo '%>';?>
      <div class="progress progress-success progress-striped active" role="progressbar" aria-valuemin="0" aria-valuemax="100">
        <div class="bar" style="width:0%;"></div>
      </div>
      <?php echo '<%';?> } else if (status == 1) { <?php echo '%>';?>
      <input type="hidden" name="images[]" value="<?php echo '<%';?>= _.escape(result) <?php echo '%>';?>">
      <span class="label label-success">Completato</span>
      <?php echo '<%';?> } else if (status == 2) { <?php echo '%>';?>
      <span class="label">Annullato</span>
      <?php echo '<%';?> } else if (status == 3) { <?php echo '%>';?>
      <span class="label label-important">Errore</span>
      <?php echo '<%';?> } <?php echo '%>';?>
    </td>
    <td width="20%" class="text-right">
      <?php echo '<%';?> if (status == 0) { <?php echo '%>';?>
      <a href="#" class="btn btn-default btn-xs btn-danger" data-behaviour="fileupload-cancel">
        <i class="glyphicon-ban-circle glyphicon"></i> Annulla
      </a>
      <?php echo '<%';?> } else { <?php echo '%>';?>
      <a href="#" class="btn btn-default btn-xs btn-danger" data-behaviour="fileupload-remove">
        <i class="glyphicon-remove glyphicon"></i> Rimuovi
      </a>
      <?php echo '<%';?> } <?php echo '%>';?>
    </td>
  </tr>
<?php echo '</script'; ?>
>
<?php }
}