function creer_champs_extras($champs) { // the function updates the tables in question using maj_tables() // [...] // It then tests if the new fields have actually been created: // for each column to be created, check that is actually exists now! $trouver_table = charger_fonction('trouver_table','base'); $trouver_table(''); // recreate the description of the tables. $retour = true; foreach ($champs as $c){ if ($table = table_objet_sql($c->table)) { $desc = $trouver_table($table); if (!isset($desc['field'][$c->champ])) { extras_log("Le champ extra '" . $c->champ . "' sur $table n'a pas ete cree :(", true); $retour = false; } } else { $retour = false; } } return $retour; }