diff --git a/src/Sikofitt/Controller/ApiControllerProvider.php b/src/Sikofitt/Controller/ApiControllerProvider.php index 9e92892..af6f5e5 100644 --- a/src/Sikofitt/Controller/ApiControllerProvider.php +++ b/src/Sikofitt/Controller/ApiControllerProvider.php @@ -137,13 +137,14 @@ class ApiControllerProvider implements ControllerProviderInterface { $contactFormName = $contactFormData['contact']['name']; $contactFormEmail = $contactFormData['contact']['email']; $contactFormMessage = $contactFormData['contact']['message']; - $message = $contactFormMessage . "\n\nEmail : " . $contactFormName . '<' . $contactFormEmail . '>'; + $message = sprintf("%s\n\nEmail : %s <%s>", $contactFormMessage, $contactFormName, $contactFormEmail); $failures = ''; $sent = $app['mailer']->send(\Swift_Message::newInstance() ->setSubject('[Resume] Message') ->setFrom(['no-reply@rewiv.com' => $contactFormName]) - ->setTo($app->config('app.email')) + ->setTo([$app->config('app.email') => 'No-Reply']) + ->setReplyTo([$contactFormEmail => $contactFormName]) ->setBody($message) , $failures); if($sent > 0) {