Afficher un message
Vieux 16/11/2006, 10h14   #1
Peggy Schatz
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut if-else-routine bundled

Hello,

in various templates and multiple times within templates I have the
following construct:

{if is_array($TemplateVar.value) }
<td>{html_options name=$TemplateVar.name options=$TemplateVar.value
selected=$selected class="bg`$TemplateVar.farbe`"
style="width:`$TemplateVar.breite`px" onchange=$TemplateVar.js}</td>
{else}
<td><input type="text" name="{$TemplateVar.name}"
value="{$TemplateVar.value}" class="bg{$TemplateVar.farbe}"
size="{$TemplateVar.breite}" {$TemplateVar.readstatus} /></td>
{/if}

I was wondering, whether there'd be a more convinient way to do that
without performance loss.
Would a plugin be a good idea? What (else) would you recommend??

Thanx in advance,
Peggy
  Réponse avec citation
 
Page generated in 0,04897 seconds with 9 queries