Comment récupérer les résultat de mon formulaire

Résolu
Ibnomar Messages postés 1 Statut Membre -  
 Ibnomar -
Please , how can I display the data of my multiple form ( <input type= “Checkbox” name=“profile “) ? When I use the function print_r (print_r($_POST[‘profile’] )) , it show array [0] =>teacher, array[1]=>pilote...
how can it display my data without these array[0] =>... ?

1 réponse

  1. jordane45 Messages postés 30426 Date d'inscription   Statut Modérateur Dernière intervention   4 830
     
    hello
    you can iterate on your array...
    $profil = !empty($_POST['profile']) ? $_POST['profile'] : array();
    foreach($profil as $P ){
      echo $P;
    }
    


    PS: .. You are on french forum. In future, please, use french language to post your questions.

    0
    1. Ibnomar
       
      Ok ! Compris . Merci pour la réponse
      0