From 439d1841b688d5ba1f2e5f99b01d4cb0de49fbaa Mon Sep 17 00:00:00 2001 From: "Cathy J. Fitzpatrick" Date: Wed, 24 Apr 2013 15:53:05 -0600 Subject: [PATCH] Correct `Content-Type` in customcss.php --- customcss.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/customcss.php b/customcss.php index ea8ed82f7..d0d494846 100644 --- a/customcss.php +++ b/customcss.php @@ -2,13 +2,15 @@ include '../pokemonshowdown.com/config/servers.inc.php'; -header('Content-type: text/css'); - $server = @$_REQUEST['server']; if (empty($PokemonServers[$server])) { + header('Content-Type: text/plain; charset=utf-8'); die('server not found'); } -$serverdata = $PokemonServers[$server]; + +header('Content-Type: text/css'); // the CSS file should specify a charset + +$serverdata =& $PokemonServers[$server]; $customcssuri = @$serverdata['customcss']; if (empty($customcssuri)) { $customcssuri = 'http://'.$serverdata['server'].':'.$serverdata['port'].'/custom.css';