add zero to first in php code example Example: prepend 0 to number php str_pad($month, 2, '0', STR_PAD_LEFT);