Mailinglisten-Archive |
Hi,
> Ich weiß jetzt schon mal daß es so:
>
> $value[] = number_format($_SESSION[preis],0,"",".").if($_SESSION[vhb]){" VHB";}
>
> nicht funktioniert :-)
davon ab, daß es als Mehrzeiler kein Problem ist, also
$value[] = number_format($_SESSION[preis],0,"",".");
if($_SESSION[vhb]){
$value[] .= " VHB";
}
Geht das auch mit [bedingung]?[fals wahr]:[falls falsch]
also so:
$value[] = number_format($_SESSION[preis],0,"",".").($_SESSION[vhb])?" VHB":"";
Gruß, Reinhold
--
Reinhold Jordan
WWW: http://reinhold.bachrain.de Mail: reinhold at bachrain.de
"The first time you'll get a Microsoft product, that doesn't suck,
will be the day they start producing vacuum cleaners." (unknown)
php::bar PHP Wiki - Listenarchive