Q:

Write a PHP script to get the number of the month before the current month

0

Write a PHP script to get the number of the month before the current month

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

<?php
echo date('m', strtotime('-1 month'))."\n";
?>

Sample Output:

06

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now