php - Smarty - Fill a table with Arrays -


in php class i'm sending on arrays, every contract customer has row in table should filled. got mistakes date:

on line 70 "{$date[$id] | date_format: %d %m %y}" - unexpected "|"

also errors other arrays

<table class="table table-hover">             <thead>             <tr>                 <td>id</td>                 <td>datum</td>                 <td>preis</td>                 <td>verbrauch</td>                 <td>abnahmestellen</td>                 <td>status</td>             </tr>             </thead>             <tbody>              {foreach from=$contractcount item=item  key=key}                 <tr>                     <td>                         <a href="{system::getlink('contractview')}"><input type="button" style="text-align: center" width="200em"  value="gehe zu "></a>{$id+1}                     </td>                     <td>                         {$date[$id] | date_format: %d %m %y}                     </td>                     <td>                         {$kwhrate[$id]}                     </td>                     <td>                         {$totalusage[$id]}                     </td>                     <td>                         {$consumptionspoints[$id]}                     </td>                     <td>                         {if $status[$id] == 0}                             <span {literal}style="background-color:#ff9933"{/literal}>in bearbeitung</span>                         {/if}                         {if $item->status[$id] == 1}                             <span  {literal}style="background-color:#ff0000"{/literal}>abgeschlossen</span>                         {/if}                         {if $item->status[$id] == 2}                             <span {literal}style="background-color:#33cc33"{/literal}>stoniert</span>                         {/if}                     </td>                 </tr>             {/foreach}             </tbody>         </table> 


Comments

Popular posts from this blog

javascript - Clear button on addentry page doesn't work -

c# - Selenium Authentication Popup preventing driver close or quit -

tensorflow when input_data MNIST_data , zlib.error: Error -3 while decompressing: invalid block type -