$data = MultiPort::getUserAppointment($userObj, $msg_id);
        if ($data['flags'] & ADA_EVENT_PROPOSAL_OK) {
            /*
             * The user accepted one of the three proposed dates for the appointment.
             * E' UN CASO CHE NON SI PUO' VERIFICARE, visto che vogliamo che l'appuntamento
             * venga inserito non appena l'utente accetta una data porposta dal practitioner
             */
            $form = CommunicationModuleHtmlLib::getConfirmedEventProposalForm($data);
        } else {
            /*
             * The user did not accept the proposed dates for the appointment
             */
            $_SESSION['event_msg_id'] = $msg_id;
            $id_user = $data['id_mittente'];
            $errors = array();
            $form = CommunicationModuleHtmlLib::getEventProposalForm($id_user, $data, $errors, $sess_selected_tester);
        }
    } else {
        /*
         * Build the form used to propose an event. Da modificare in modo da passare
         * eventualmente il contenuto dei campi del form nel caso si stia inviando
         * una modifica ad una proposta di appuntamento.
         */
        $errors = array();
        $data = array();
        $form = CommunicationModuleHtmlLib::getEventProposalForm($sess_id_user, $data, $errors, $sess_selected_tester);
    }
}
$title = translateFN('Invia proposta di appuntamento');
$content_dataAr = array('user_name' => $user_name, 'user_type' => $user_type, 'titolo' => $titolo, 'course_title' => '<a href="../browsing/main_index.php">' . $course_title . '</a>', 'status' => $err_msg, 'data' => $form->getHtml(), 'label' => $title);
ARE::render($layout_dataAr, $content_dataAr);