Viewing file: 6ae8652bf6ad92a7bafa08b2477dbe3e098311e9.file.user-year-form.tpl.php (5.41 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php /* Smarty version Smarty3-RC3, created on 2014-09-26 00:18:22 compiled from "user/templates/announcements/user-year-form.tpl" */ ?> <?php /*%%SmartyHeaderCode:19327912425424869eeb7197-03151415%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed'); $_smarty_tpl->decodeProperties(array ( 'file_dependency' => array ( '6ae8652bf6ad92a7bafa08b2477dbe3e098311e9' => array ( 0 => 'user/templates/announcements/user-year-form.tpl', 1 => 1410983472, ), ), 'nocache_hash' => '19327912425424869eeb7197-03151415', 'function' => array ( ), 'has_nocache_code' => false, )); /*/%%SmartyHeaderCode%%*/?> <div class="archive-selector"> <form name="announcement-year-form" method="get" id="announcement-year-form"> <label><?php echo $_smarty_tpl->getVariable('ULANG')->value['AnnouncementsYearSelector'];?> : </label><select name="announcement-year-select" id="announcement-year-select"> <option value="now"><?php echo $_smarty_tpl->getVariable('ULANG')->value['AnnouncementsCurrentYear'];?> </option> <?php ob_start();?><?php echo GetCurrentYear()+1;?> <?php $_tmp1=ob_get_clean();?><?php ob_start();?><?php echo GetParam("StartYear");?> <?php $_tmp2=ob_get_clean();?><?php ob_start();?><?php echo GetCurrentYear()-$_tmp2+1;?> <?php $_tmp3=ob_get_clean();?><?php unset($_smarty_tpl->tpl_vars['smarty']->value['section']['year']); $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['name'] = 'year'; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['loop'] = is_array($_loop=$_tmp1) ? count($_loop) : max(0, (int)$_loop); unset($_loop); $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['max'] = (int)$_tmp3; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['step'] = ((int)-1) == 0 ? 1 : (int)-1; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['show'] = true; if ($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['max'] < 0) $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['max'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['loop']; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['start'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['step'] > 0 ? 0 : $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['loop']-1; if ($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['show']) { $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['total'] = min(ceil(($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['step'] > 0 ? $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['loop'] - $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['start'] : $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['start']+1)/abs($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['step'])), $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['max']); if ($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['total'] == 0) $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['show'] = false; } else $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['total'] = 0; if ($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['show']):
for ($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['index'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['start'], $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['iteration'] = 1; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['iteration'] <= $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['total']; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['index'] += $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['step'], $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['iteration']++): $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['rownum'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['iteration']; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['index_prev'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['index'] - $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['step']; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['index_next'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['index'] + $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['step']; $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['first'] = ($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['iteration'] == 1); $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['last'] = ($_smarty_tpl->tpl_vars['smarty']->value['section']['year']['iteration'] == $_smarty_tpl->tpl_vars['smarty']->value['section']['year']['total']); ?> <option value="<?php echo $_smarty_tpl->getVariable('smarty')->value['section']['year']['index'];?> " <?php if ($_smarty_tpl->getVariable('smarty')->value['section']['year']['index']==$_GET['list']){?> selected="selected" <?php }?>><?php echo $_smarty_tpl->getVariable('ULANG')->value['AnnouncementsArchive'];?> <?php echo $_smarty_tpl->getVariable('smarty')->value['section']['year']['index'];?> <?php echo $_smarty_tpl->getVariable('ULANG')->value['CoreYearRP'];?> </option> <?php endfor; endif; ?> </select> </form> </div> <script type="text/javascript"> $(document).ready(function() { $("#announcement-year-select").change(function() { document.location.href = "/announcements/archive/" + $("#announcement-year-select").val(); });
}); </script>
|