Started to use PHP about 2 weeks ago,got first problems =D
Can't figure how to get my task done.
Program have to give next upcoming birthday and name.Thanks in advance
How to make this programm print out something like :
Jessy Pinkmann 2017-09-11
<?php
$today=new DateTime();
$Bdays = array
(
array("Lucienne Adkisson",date_create("2017-10-17")), //0 // Y/M/D
array("Sheryll Nestle",date_create("2017-02-16")), //1
array("Tim Pittman",date_create("2017-07-29")), //2
array("Elmer Letts",date_create("2017-12-01")), //3
array("Gino Massengale",date_create("2017-04-16")), //4
array("Jeremy Wiggs ",date_create("2017-09-17")), //5
array("Julian Bulloch ",date_create("2017-06 -21")), //6
array("Joella Hinshaw ",date_create("2017-06-25")), //7
array("Mamie Burchill ",date_create("2017-11-15")), //8
array("Constance Segers ",date_create("2017-06-30")), //9
array("Jessy Pinkmann",date_create("2017-09-11")), //10
array("Dudley Currie",date_create("2017-02-10")) //11
);
for ($x =0; $x <= 11; $x++ ){
$diff=date_diff($today,$Bdays[$x][1]);
echo $diff->format(" %R%a");
}
?>