- $globals->xdb->execute('INSERT INTO x4dat.virtual (alias,type)
- VALUES({?},{?})', $liste.'@'.$dom, 'list');
- $globals->xdb->execute('INSERT INTO x4dat.virtual_redirect (vid,redirect)
- VALUES ({?}, {?})', mysql_insert_id(),
- "$red+post@listes.polytechnique.org");
- $globals->xdb->execute('INSERT INTO x4dat.virtual (alias,type)
- VALUES({?},{?})', $liste.'-owner@'.$dom, 'list');
- $globals->xdb->execute('INSERT INTO x4dat.virtual_redirect (vid,redirect)
- VALUES ({?}, {?})', mysql_insert_id(),
- "$red+owner@listes.polytechnique.org");
- $globals->xdb->execute('INSERT INTO x4dat.virtual (alias,type)
- VALUES({?},{?})', $liste.'-admin@'.$dom, 'list');
- $globals->xdb->execute('INSERT INTO x4dat.virtual_redirect (vid,redirect)
- VALUES ({?}, {?})', mysql_insert_id(),
- "$red+admin@listes.polytechnique.org");
- $globals->xdb->execute('INSERT INTO x4dat.virtual (alias,type)
- VALUES({?},{?})', $liste.'-bounces@'.$dom, 'list');
- $globals->xdb->execute('INSERT INTO x4dat.virtual_redirect (vid,redirect)
- VALUES ({?}, {?})', mysql_insert_id(),
- "$red+bounces@listes.polytechnique.org");
-
- global $platal;
- redirect(smarty_function_rel().'/'.$platal->ns.'lists/admin/'.$liste);
+ create_list($list, $globals->asso('mail_domain'));
+
+ XDB::execute("UPDATE groups
+ SET flags = CONCAT_WS(',', IF(flags = '', NULL, flags), 'has_ml')
+ WHERE id = {?}",
+ $globals->asso('id'));
+
+ pl_redirect('lists/admin/' . $list);