* @version $Id$ * @access public * @license http://opensource.org/licenses/gpl-3.0.html */ ?> isSuperAdmin()) ReloadIndex('admin'); //////////// // TextboxList CSS/JS inclusion addDynamicCSS(THEME_ADMIN_PATH.'css/TextboxList.css'); addDynamicCSS(THEME_ADMIN_PATH.'css/TextboxList.Autocomplete.css'); footerAddJS('../lib/js/TextboxList-jQuery/Source/GrowingInput.js'); footerAddJS('../lib/js/TextboxList-jQuery/Source/TextboxList.js'); footerAddJS('../lib/js/TextboxList-jQuery/Source/TextboxList.Autocomplete.js'); $workshop_object= new workshop; if(isset($_POST['enregistrer'])) { $data_table=unserialize(urldecode($_POST['data_table'])); $result=$workshop_object->AddWorkshop($data_table, $sql_object); $data_table[5]=str_replace(" ","", $data_table[5]); $table_organizer=@explode(',',$data_table[5]); for ($i=0;$iAddUserWorkshop($result, trim($table_organizer[$i]), "O" , $sql_object); } $link_confirm="confirm.php?rub=".$rub."&todo=".$todo; if(is_numeric($result)) { header("Location: ".safe_redirect($link_confirm)); exit; } else system_error(); } if(isset($_POST['valider'])) { $table = array(); $table[0]=$_POST['workshop_denomination']; $table[1]=$_POST['workshop_resume']; $table[2]=$_POST['workshop_level']; $table[3]=$_POST['workshop_comment']; $table[4]=$_POST['workshop_statut']; $table[5]=$_POST['workshop_organizer']; $table[6]=$_POST['workshop_restricted']; $table[7]=$_POST['workshop_visible']; $workshop_object= new workshop; $integrity=$workshop_object->CheckDataIntegrity($table, $sql_object); if(is_string($integrity)) { $text_format='2FIELD'; } else { $text_format='2HTML'; } $form_denomination=formatText($_POST['workshop_denomination'], $text_format); $form_resume=formatText($_POST['workshop_resume'], $text_format); $form_level=$_POST['workshop_level']; $form_organizer=formatText(str_replace(",",", ", $_POST['workshop_organizer']), $text_format); $form_comment=formatText($_POST['workshop_comment'], $text_format); if($_POST['workshop_restricted'] == 1) { $display_form_restricted = _t('divers', 'yes'); } else { $display_form_restricted = _t('divers', 'no'); } if($_POST['workshop_visible'] == 1) { $display_form_visible = _t('divers', 'yes'); } else { $display_form_visible = _t('divers', 'no'); } if($_POST['workshop_statut']=='D') $mask_statut_D="checked=\"checked\""; else $mask_statut_D=''; if($_POST['workshop_statut']=='P') $mask_statut_P="checked=\"checked\""; else $mask_statut_P=''; if($_POST['workshop_restricted']==0) $mask_restricted_N="checked=\"checked\""; else $mask_restricted_N=''; if($_POST['workshop_restricted']==1) $mask_restricted_Y="checked=\"checked\""; else $mask_restricted_Y=''; if($_POST['workshop_visible']==0) $mask_visible_N="checked=\"checked\""; else $mask_visible_N=''; if($_POST['workshop_visible']==1) $mask_visible_Y="checked=\"checked\""; else $mask_visible_Y=''; $table=urlencode(serialize($table)); } if(!isset($integrity) || is_string($integrity)) { // select-box des niveaux $data=$sql_object->DBSelect(SQL_getLevelsList()); $select_level=LevelSelectBox($data, "workshop_level", $form_level); } ?>

:
required /> />

:
required /> />

:
required /> />

DBSelect(SQL_getoneLevel($form_level)); $level_name=formatText($record[0]['level_name'], '2HTML'); } $display_form_resume=empty_nc($form_resume); $display_form_comment=empty_nc($form_comment); ?>

\n"; echo "
".mb_ucfirst(_t('workshop','title'))." :
\n"; echo "
". $form_denomination."
\n"; echo "
".mb_ucfirst(_t('workshop','resume')). " :
\n"; echo "
".$display_form_resume."
\n"; echo "
".mb_ucfirst(_t('workshop','organizer'))." :
\n"; echo "
".$form_organizer."
\n"; echo "
".mb_ucfirst(_t('workshop','restricted')). " :
\n"; echo "
".$display_form_restricted."
\n"; echo "
".mb_ucfirst(_t('workshop','visible')). " :
\n"; echo "
".$display_form_visible."
\n"; echo "
".mb_ucfirst(_t('workshop','level'))." :
\n"; echo "
".$level_name."
\n"; echo "
".mb_ucfirst(_t('divers','statut')) ." :
\n"; echo "
". display_statut($_POST['workshop_statut']). "
\n"; echo "
".mb_ucfirst(_t('workshop','comment')) ." :
\n"; echo "
". $display_form_comment. "
\n"; echo "\n"; ?>