/** * Send Contact Email. * * @return Response */ public function contact() { // Get the contact info from DB $user = $this->contactRepository->getFirst(); // Validate the input data $val = $this->contactRepository->getContactForm(); if (!$val->isValid()) { return Redirect::back()->withInput()->with('errors', $val->getErrors()); } $input = array_merge(Input::only(['sender_name', 'sender_email', 'body']), $user->toArray()); Event::fire('contact.contact', [$input]); return Redirect::home()->with('success', trans('word.mail_sent')); }