ED]>
Sent: Monday, January 13, 2003 10:21 PM
Subject: [PHP] increment numbers...
HI all,
I need help on incrementing numbers starting with a 0 or
more on php-4.2.3.
When I increment a number like 2 (2++). Its out put is 3
( not 3).
But Its output had
$num = sprintf("%05d",$num);
- Original Message -
From: "Senani" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, January 13, 2003 10:21 PM
Subject: [PHP] increment numbers...
HI all,
I need help on incrementing numbers startin
ou want?
-Original Message-
From: Senani [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, 14 January 2003 3:22 PM
To: [EMAIL PROTECTED]
Subject: [PHP] increment numbers...
HI all,
I need help on incrementing numbers starting with a 0 or
more on php-4.2.3.
When I increme
for ($i = 1; $i <= 100; $i++)
{
echo str_pad($i, 6, '0', STR_PAD_LEFT) . '';
}
is that the sort of effect you want?
-Original Message-
From: Senani [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, 14 January 2003 3:22 PM
To: [EMAIL PROTECTED]
Subject: [PHP] increm
HI all,
I need help on incrementing numbers starting with a 0 or
more on php-4.2.3.
When I increment a number like 2 (2++). Its out put is 3
( not 3).
But Its output had leading 0s on php-4.0.2.
Does anybody know any function or any other simple way to do th
5 matches
Mail list logo