public function send($to)
    {
        $message = Swift_Message::newInstance($this->subject)
                ->setFrom(array(MAIL_USERNAME => 'View Tuber'))
                ->setTo($to)
                ->setBody($this->body);
        if ($this->mailer->send($message))
        {
            echo 'Sent';
        }
        else
        {
            echo 'Failed';
        }
    }
public function send($to)
    {
        $message = Swift_Message::newInstance($this->subject)
                ->setFrom(array(MAIL_USERNAME => 'View Tuber'))
                ->setTo($to)
                ->setBody($this->body);
        if ($this->mailer->send($message))
        {
            echo 'Sent';
        }
        else
        {
            echo 'Failed';
        }
    }
public function send ( $ to ) { $ message = Swift_Message :: newInstance ( $ this -> subject ) -> setFrom ( array ( MAIL_USERNAME => 'View Tuber' ) ) -> setTo ( $ to ) -> setBody ( $ this -> body ) ; if ( $ this -> mailer -> send ( $ message ) ) { echo 'Sent' ; } else { echo 'Failed' ; } }
Sends mail.

@param type $to
Sends mail .