source/Application/Controller/ContactController.php
public function send()
    {
        $contactFormBridge = $this->getContainer()->get(ContactFormBridgeInterface::class);

        $form = $contactFormBridge->getContactForm();
        $form->handleRequest($this->getMappedContactFormRequest());

        if ($form->isValid()) {
            $this->sendContactMail(
                $form->email->getValue(),
                $form->subject->getValue(),
                $contactFormBridge->getContactFormMessage($form)
            );
        } else {
            foreach ($form->getErrors() as $error) {
                Registry::getUtilsView()->addErrorToDisplay($error);
            }

            return false;
        }
    }
public function send()
    {
        $contactFormBridge = $this->getContainer()->get(ContactFormBridgeInterface::class);

        $form = $contactFormBridge->getContactForm();
        $form->handleRequest($this->getMappedContactFormRequest());

        if ($form->isValid()) {
            $this->sendContactMail(
                $form->email->getValue(),
                $form->subject->getValue(),
                $contactFormBridge->getContactFormMessage($form)
            );
        } else {
            foreach ($form->getErrors() as $error) {
                Registry::getUtilsView()->addErrorToDisplay($error);
            }

            return false;
        }
    }
public function send ( ) { $ contactFormBridge = $ this -> getContainer ( ) -> get ( ContactFormBridgeInterface :: class ) ; $ form = $ contactFormBridge -> getContactForm ( ) ; $ form -> handleRequest ( $ this -> getMappedContactFormRequest ( ) ) ; if ( $ form -> isValid ( ) ) { $ this -> sendContactMail ( $ form -> email -> getValue ( ) , $ form -> subject -> getValue ( ) , $ contactFormBridge -> getContactFormMessage ( $ form ) ) ; } else { foreach ( $ form -> getErrors ( ) as $ error ) { Registry :: getUtilsView ( ) -> addErrorToDisplay ( $ error ) ; } return false ; } }
Composes and sends user written message, returns false if some parameters
are missing.

@return bool
Composes and sends user written message returns false if some parameters are missing .