Re: string
| From: | Remy Dufour | Date: | Mon, 17 Jun 2002 13:50:53 +0000 |
| Subject: | Re: string | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-102511@lists.php.net to get a copy of this message | ||
> $productid .= "0";
>
> should do the trick ;)
This will give "80"
I think the solution is
$productid = str_pad($productid, 2, '0', STR_PAD_LEFT);
http://www.php.net/manual/en/function.str-pad.php
Rémy Dufour