From f5fea9c3d3147db50f7f6eb32c25e4e8bea15f0d Mon Sep 17 00:00:00 2001 From: David Anderson Date: Fri, 28 Mar 2014 14:52:37 -0700 Subject: [PATCH] team_import script: decode entities properly --- doc/logo.php | 4 ++++ html/ops/manage_special_users.php | 2 +- html/ops/team_import.php | 20 ++++++++++++-------- 3 files changed, 17 insertions(+), 9 deletions(-) diff --git a/doc/logo.php b/doc/logo.php index 83eedc2244..0c5716a407 100644 --- a/doc/logo.php +++ b/doc/logo.php @@ -82,6 +82,10 @@ $wallpaper = array( " ), + array( + "Jacob Klein", + "" + ), ); art_list_head(); art_list_show($wallpaper); diff --git a/html/ops/manage_special_users.php b/html/ops/manage_special_users.php index cb12448bfc..914bc35944 100644 --- a/html/ops/manage_special_users.php +++ b/html/ops/manage_special_users.php @@ -21,7 +21,7 @@ require_once('../inc/util_ops.inc'); db_init(); -admin_page_head('Manage special users'); +admin_page_head('Manage user privileges'); start_table("align=\"center\""); row1("Current special users", '9'); diff --git a/html/ops/team_import.php b/html/ops/team_import.php index e96accd08c..b3e3863f53 100755 --- a/html/ops/team_import.php +++ b/html/ops/team_import.php @@ -52,17 +52,21 @@ function lookup_team_seti_id($id) { return null; } +function decode($x) { + return html_entity_decode($x, ENT_COMPAT, 'UTF-8'); +} + function parse_team($f) { while ($s = fgets($f)) { if (strstr($s, '')) { - $t->name = htmlspecialchars_decode($t->name); - $t->url = htmlspecialchars_decode($t->url); - $t->name_html = htmlspecialchars_decode($t->name_html); - $t->description = htmlspecialchars_decode($t->description); - $t->user_name = htmlspecialchars_decode($t->user_name); - $t->user_country = htmlspecialchars_decode($t->user_country); - $t->user_postal_code = htmlspecialchars_decode($t->user_postal_code); - $t->user_url = htmlspecialchars_decode($t->user_url); + $t->name = decode($t->name); + $t->url = decode($t->url); + $t->name_html = decode($t->name_html); + $t->description = decode($t->description); + $t->user_name = decode($t->user_name); + $t->user_country = decode($t->user_country); + $t->user_postal_code = decode($t->user_postal_code); + $t->user_url = decode($t->user_url); return $t; } else if (strstr($s, '')) $t->name = parse_element($s, '');