samedi 1 avril 2017

How do i use Arrays in functions with PHP?

What's wrong with the code I dont know how to fix it and can you do this with arrays?

function theDate($date) {
    echo $date[0]. " ".$date[1] . " ".$date[2];
}

$date = array("April", "1st", "2017");


theDate($date[0], $date[1], $date[2]);
?>




Aucun commentaire:

Enregistrer un commentaire