home *** CD-ROM | disk | FTP | other *** search
/ PC Professionell 2005 June / PCpro_2005_06.ISO / files / opensource / xamp / xampp-win32.exe / xampp / todolist.tpl < prev    next >
Encoding:
Text File  |  2004-03-24  |  4.4 KB  |  75 lines

  1. <?php /* Smarty version 2.5.0, created on 2003-04-23 22:09:15
  2.          compiled from todolist.tpl */ ?>
  3. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  4. $this->_smarty_include("header.tpl", array('title' => 'Todo List'));
  5. $this->_tpl_vars = $_smarty_tpl_vars;
  6. unset($_smarty_tpl_vars);
  7.  ?>
  8. <div align="center"><h1>Todo List</h1></div>
  9. <?php if (count((array)$this->_tpl_vars['todos'])):
  10.     foreach ((array)$this->_tpl_vars['todos'] as $this->_tpl_vars['todopackage'] => $this->_tpl_vars['todo']):
  11. ?>
  12. <h2><?php echo $this->_tpl_vars['todopackage']; ?>
  13. </h2>
  14. <?php if (isset($this->_sections['todo'])) unset($this->_sections['todo']);
  15. $this->_sections['todo']['name'] = 'todo';
  16. $this->_sections['todo']['loop'] = is_array($this->_tpl_vars['todo']) ? count($this->_tpl_vars['todo']) : max(0, (int)$this->_tpl_vars['todo']);
  17. $this->_sections['todo']['show'] = true;
  18. $this->_sections['todo']['max'] = $this->_sections['todo']['loop'];
  19. $this->_sections['todo']['step'] = 1;
  20. $this->_sections['todo']['start'] = $this->_sections['todo']['step'] > 0 ? 0 : $this->_sections['todo']['loop']-1;
  21. if ($this->_sections['todo']['show']) {
  22.     $this->_sections['todo']['total'] = $this->_sections['todo']['loop'];
  23.     if ($this->_sections['todo']['total'] == 0)
  24.         $this->_sections['todo']['show'] = false;
  25. } else
  26.     $this->_sections['todo']['total'] = 0;
  27. if ($this->_sections['todo']['show']):
  28.  
  29.             for ($this->_sections['todo']['index'] = $this->_sections['todo']['start'], $this->_sections['todo']['iteration'] = 1;
  30.                  $this->_sections['todo']['iteration'] <= $this->_sections['todo']['total'];
  31.                  $this->_sections['todo']['index'] += $this->_sections['todo']['step'], $this->_sections['todo']['iteration']++):
  32. $this->_sections['todo']['rownum'] = $this->_sections['todo']['iteration'];
  33. $this->_sections['todo']['index_prev'] = $this->_sections['todo']['index'] - $this->_sections['todo']['step'];
  34. $this->_sections['todo']['index_next'] = $this->_sections['todo']['index'] + $this->_sections['todo']['step'];
  35. $this->_sections['todo']['first']      = ($this->_sections['todo']['iteration'] == 1);
  36. $this->_sections['todo']['last']       = ($this->_sections['todo']['iteration'] == $this->_sections['todo']['total']);
  37. ?>
  38. <h3><?php echo $this->_tpl_vars['todo'][$this->_sections['todo']['index']]['link']; ?>
  39. </h3>
  40. <ul>
  41. <?php if (isset($this->_sections['t'])) unset($this->_sections['t']);
  42. $this->_sections['t']['name'] = 't';
  43. $this->_sections['t']['loop'] = is_array($this->_tpl_vars['todo'][$this->_sections['todo']['index']]['todos']) ? count($this->_tpl_vars['todo'][$this->_sections['todo']['index']]['todos']) : max(0, (int)$this->_tpl_vars['todo'][$this->_sections['todo']['index']]['todos']);
  44. $this->_sections['t']['show'] = true;
  45. $this->_sections['t']['max'] = $this->_sections['t']['loop'];
  46. $this->_sections['t']['step'] = 1;
  47. $this->_sections['t']['start'] = $this->_sections['t']['step'] > 0 ? 0 : $this->_sections['t']['loop']-1;
  48. if ($this->_sections['t']['show']) {
  49.     $this->_sections['t']['total'] = $this->_sections['t']['loop'];
  50.     if ($this->_sections['t']['total'] == 0)
  51.         $this->_sections['t']['show'] = false;
  52. } else
  53.     $this->_sections['t']['total'] = 0;
  54. if ($this->_sections['t']['show']):
  55.  
  56.             for ($this->_sections['t']['index'] = $this->_sections['t']['start'], $this->_sections['t']['iteration'] = 1;
  57.                  $this->_sections['t']['iteration'] <= $this->_sections['t']['total'];
  58.                  $this->_sections['t']['index'] += $this->_sections['t']['step'], $this->_sections['t']['iteration']++):
  59. $this->_sections['t']['rownum'] = $this->_sections['t']['iteration'];
  60. $this->_sections['t']['index_prev'] = $this->_sections['t']['index'] - $this->_sections['t']['step'];
  61. $this->_sections['t']['index_next'] = $this->_sections['t']['index'] + $this->_sections['t']['step'];
  62. $this->_sections['t']['first']      = ($this->_sections['t']['iteration'] == 1);
  63. $this->_sections['t']['last']       = ($this->_sections['t']['iteration'] == $this->_sections['t']['total']);
  64. ?>
  65.     <li><?php echo $this->_tpl_vars['todo'][$this->_sections['todo']['index']]['todos'][$this->_sections['t']['index']]; ?>
  66. </li>
  67. <?php endfor; endif; ?>
  68. </ul>
  69. <?php endfor; endif; ?>
  70. <?php endforeach; endif; ?>
  71. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  72. $this->_smarty_include("footer.tpl", array());
  73. $this->_tpl_vars = $_smarty_tpl_vars;
  74. unset($_smarty_tpl_vars);
  75.  ?>