Beispiel #1
0
 if ($textTitre) {
     $cree = 0;
     $newForma = new Formation();
     $newForma->titrePara = $textTitre;
     $newForma->contenuPara = $textCont;
     $newForma->datedeb_admin = $textDateDeb;
     $newForma->datefin_admin = $textDateFin;
     $newForma->surMesure = $radioMesure;
     $newForma->enligne = $radioEnligne;
     $newForma->numpara = $numpara;
     if (!$numpara) {
         $numpara = $newForma->creerParagraphe();
         $newForma->creerFormation();
         $cree = 1;
     } else {
         $newForma->modifierParagraphe();
         $newForma->modifierFormation();
     }
     if (is_array($selectCateg)) {
         $newForma->listcateg = $selectCateg;
         $newForma->associerFormaCateg();
     }
     if (is_array($selectSscateg)) {
         $newForma->listsscateg = $selectSscateg;
         $newForma->associerFormaSscateg();
     }
     if ($selectFich || isset($_FILES["fileFiche"]['tmp_name']) && $_FILES["fileFiche"]['tmp_name'] != "") {
         if ($selectFich) {
             // on associe une fiche formation existante
             $newForma->numfichier = $selectFich;
             $newForma->associerFichier();