- or download this
$newfile = "0001"; # Initialize to 0001
++$newfile; # Now contains 0002
- or download this
$newfile = "0001"; # Initialize to 0001
$newfile = sprintf("%04d", $newfile+1); # Now contains 0002
- or download this
$newfile = "0001"; # Initialzie to 0001
$newfile += 1; # Now contains 2