But that's not much different than what you had.$var = "0" x 10; $string = "test"; substr($var, -length($string)) = $string;
Oops: You said right, not left. Nevermind.
In reply to Re: clever zero _right_ pad?
by Fastolfe
in thread clever zero _right_ pad?
by jimt
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |