You can use an “array” :

$to = array(
            "user1@gmail.com" => "User 1",
            "user2@gmail.com" => "User 2"
        );

 

Example :

$subject = "User";

        $to = array(
            "user1@gmail.com" => "User 1",
            "user2@gmail.com" => "User 2"
        );

        $from = "contact@become-developer.com";
        $name = "Become Developer";

        $body = "content";

$message = \Swift_Message::newInstance()
            ->setSubject($subject)
            ->setFrom($from)
            ->setTo($to)
            ->setBody($body)
            /*
             * If you also want to include a plaintext version of the message
            ->addPart(
                $this->renderView(
                    'Emails/registration.txt.twig',
                    array('name' => $name)
                ),
                'text/plain'
            )
            */
        ;

        // or, you can also fetch the mailer service this way
        // $this->get('mailer')->send($message);
        return $this->mailer->send($message);

 

This error appear because your type not a “Array”

 

Change type to “array”

    /**
     * @var string
     *
     * @ORM\Column(name="informations", type="array")
     * */
    private $informations;

Then update your database with Command Symfony

Tip :

var url = '{{ path("yourroute", {'id': 'id'}) }}'; 
url = url.replace("id", this.value);

window.location.href = url;

 

app.request.get('id')

 

Define the real entity:

 * @ORM\Entity

For example

Before :

<?php

namespace BookingBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * @ORM\Table(name="booking")
 */
class Booking
{

After :

<?php

namespace BookingBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * @ORM\Entity
 * @ORM\Table(name="booking")
 */
class Booking
{

 

I share with you the solution :

Create a link /var/www

sudo ln -s /usr/share/phpmyadmin /var/www/
sudo nano /etc/apache2/apache2.conf

Then add the following line :

Include /etc/phpmyadmin/apache.conf

then Restart your apache

sudo service apache2 reload