I want a loop like this:
This loop is OK:
while($d<=$d2) {
$x = "first day of + 1 month";
$d=strtotime($x,$d);
do_something($d);
}
But
while($d<=$d2) {
$x = "third day of + 1 month";
$d=strtotime($x,$d);
do_something($d);
}
doens't work: https://www.functions-online.com/strtotime.html gives "false" How can I solve this?
(first, second, third etc is a variable)