Changeset 861 in ExiteCMS for trunk/includes/templates/main.downloads.tpl
- Timestamp:
- 10/02/07 22:23:07 (5 years ago)
- File:
-
- 1 edited
-
trunk/includes/templates/main.downloads.tpl (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/includes/templates/main.downloads.tpl
r843 r861 16 16 {***************************************************************************} 17 17 {if $subcats}{assign var="_title" value=$locale.417}{else}{assign var="_title" value=$locale.418}{/if} 18 {assign var="columns" value="2"} {* number of columns *} 19 {math equation="(100 - x) / x" x=$columns format="%u" assign="colwidth"} 18 {assign var="have_cats" value=false} 19 {assign var="columns" value="2"} {* number of columns *} 20 {math equation="(100-x)/x" x=$columns format="%u" assign="colwidth"} {* width per column *} 20 21 {section name=cat loop=$download_cats} 21 {cycle name=column values="1,2" assign="column" print=no} {* keep track of the current column *}22 {cycle name=column values="1,2" assign="column" print=no} {* keep track of the current column *} 22 23 {if $smarty.section.cat.first} 23 {include file="_opentable.tpl" name=$_name title=$_title state=$_state style=$_style} 24 <table cellpadding='0' cellspacing='1' width='100%' class='tbl-border'> 24 {assign var="have_cats" value=true} 25 {math equation="x - (x%y)" x=$download_cats|@count y=$columns format="%u" assign="fullrows"} 26 {math equation="x - y" x=$download_cats|@count y=$fullrows format="%u" assign="remainder"} 27 {if $remainder > 0} 28 {math equation="(100 - z + y) / (z - y)" y=$fullrows z=$download_cats|@count format="%u" assign="lastwidth"} {* width last rows columns *} 29 {/if} 30 {include file="_opentable.tpl" name=$_name title=$_title state=$_state style=$_style} 31 <table cellpadding='0' cellspacing='1' width='100%' class='tbl-border'> 25 32 {/if} 26 33 {if $column == 1}<tr>{/if} … … 32 39 {/if} 33 40 </td> 41 {if $smarty.section.cat.iteration > $fullrows} 42 <td width='{$lastwidth}%' colspan='{math equation="1+(x-y)*2" x=$columns y=$remainder}' class='tbl1' style='vertical-align:top'> 43 {else} 34 44 <td width='{$colwidth}%' class='tbl1' style='vertical-align:top'> 45 {/if} 35 46 <div class='forum-caption'> 36 <img src='{$smarty.const.THEME}images/bullet.gif' alt='' >47 <img src='{$smarty.const.THEME}images/bullet.gif' alt='' /> 37 48 <a href='{$smarty.const.FUSION_SELF}?cat_id={$download_cats[cat].download_cat_id}'>{$download_cats[cat].download_cat_name}</a> 38 49 <br /> … … 47 58 {if $smarty.section.cat.last} 48 59 {if $column != $columns} 49 {section name=dummy start=$column loop=$columns} 50 <td width='{math equation='x+1' x=$colwidth}%' colspan='2' class='tbl1' style='vertical-align:top'> 51 </td> 52 {/section} 53 </tr> 60 </tr> 54 61 {/if} 55 62 </table> … … 73 80 {/if} 74 81 <tr> 75 <td colspan=' 4' class='forum-caption'>82 <td colspan='3' class='forum-caption'> 76 83 <b>{$downloads[item].download_title}</b> 84 </td> 85 <td align='right' class='forum-caption'> 86 <a href='{$smarty.const.FUSION_SELF}?cat_id={$downloads[item].download_cat}&download_id={$downloads[item].download_id}'><span class='small2'>{$locale.420}</span></a> 77 87 </td> 78 88 </tr> … … 116 126 {else} 117 127 </table> 128 {include file="_closetable.tpl"} 118 129 {/if} 119 130 {sectionelse} 120 {include file="_opentable.tpl" name=$_name title=$locale.400 state=$_state style=$_style} 121 <center> 122 <br /> 123 <b>{$locale.431}</b> 124 <br /><br /> 125 </center> 131 {if !$have_cats} 132 {include file="_opentable.tpl" name=$_name title=$locale.400 state=$_state style=$_style} 133 <center> 134 <br /> 135 <b>{$locale.431}</b> 136 <br /><br /> 137 </center> 138 {include file="_closetable.tpl"} 139 {/if} 126 140 {/section} 127 {include file="_closetable.tpl"}128 141 {***************************************************************************} 129 142 {* End of template *}
Note: See TracChangeset
for help on using the changeset viewer.
