Mailinglisten-Archive |
Nicole Simon wrote:
> Tobias Ratschiller wrote:
> > printf("%0".$length."d",$foo)
> Oh, interessant. Das ist so einfach, daß ich dachte, so geht das nienicht.
Man kann es statt als Stringoperation "const" . $variable . "const" auch
als Stringinterpolation schreiben: "const${variable}const". Das ist
marginal schneller und erzeugt einen String weniger Garbage.
Kristian
--
Kristian Köhntopp, NetUSE Kommunikationstechnologie GmbH
Siemenswall, D-24107 Kiel, Germany, +49 431 386 436 00
Using PHP3? See our web development library at
http://phplib.shonline.de/ (GPL)
php::bar PHP Wiki - Listenarchive