// to compose a message containing the submitted data, // we need to iterate through the $data array foreach($data as $field => $value){ $messageData .= "$field: $value \n"; } sendmail(array( 'to' => 'admin@soiltransfert.com', 'name' => 'SOIL TRANSFERT', 'subject' => 'ENVOI', 'message' => "Nouvel envoi de {$memberInfo['username']}: \n\n" . $messageData ));