From 8094e654c1b6d29ca64b707a55bf5ce862b06a03 Mon Sep 17 00:00:00 2001 From: "Pierre Habouzit (MadCoder" Date: Tue, 18 Jan 2005 21:32:54 +0000 Subject: [PATCH] backport Patches applied: * opensource@polytechnique.org--2005/platal--release--0.9.3--patch-34 small fixups git-archimport-id: opensource@polytechnique.org--2005/platal--mainline--0.9--patch-383 --- htdocs/groupex/export-econfiance.php | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/htdocs/groupex/export-econfiance.php b/htdocs/groupex/export-econfiance.php index 2a0aa15..67af238 100644 --- a/htdocs/groupex/export-econfiance.php +++ b/htdocs/groupex/export-econfiance.php @@ -22,8 +22,9 @@ /* Script permettant l'export de la liste des membres de la mailing list eConfiance, pour intégration par J-P Figer dans la liste des membres de X-Informatique */ -require_once("xorg.inc.php"); -require_once("xml-rpc-client.inc.php"); +require_once('xorg.inc.php'); +require_once('xml-rpc-client.inc.php'); +require_once('lists.inc.php'); $cle = $globals->econfiance; @@ -32,7 +33,7 @@ if (isset($_SESSION["chall"]) && $_SESSION["chall"] != "" && $_GET["PASS"] == md $res = $globals->xdb->query("SELECT password FROM auth_user_md5 WHERE user_id=10154"); $pass = $res->fetchOneCell(); - $client = new xmlrpc_client("http://10154:$pass@localhost:4949/polytechnique.org"); + $client =& lists_xmlrpc(10154, $pass, "polytechnique.org"); $members = $client->get_members('x-econfiance'); if(is_array($members)) { $membres = Array(); @@ -45,7 +46,7 @@ if (isset($_SESSION["chall"]) && $_SESSION["chall"] != "" && $_GET["PASS"] == md $where = join(' OR ',$membres); - $all = $globals->xdb->fetchRow( + $all = $globals->xdb->iterRow( "SELECT u.prenom,u.nom,a.alias FROM auth_user_md5 AS u INNER JOIN aliases AS a ON ( u.user_id = a.id AND a.type!='homonyme' ) @@ -56,9 +57,9 @@ if (isset($_SESSION["chall"]) && $_SESSION["chall"] != "" && $_GET["PASS"] == md while (list ($prenom1,$nom1,$email1) = $all->next()) { $res .= "\n"; - $res .= "\t".$nom1."\n"; - $res .= "\t".$prenom1."\n"; - $res .= "\t".$email1."\n"; + $res .= "\t".utf8_encode($nom1)."\n"; + $res .= "\t".utf8_encode($prenom1)."\n"; + $res .= "\t".utf8_encode($email1)."\n"; $res .= "\n\n"; } -- 2.1.4