CVS update: /cowiki/htdocs/setup/
[email protected] 24 May 2005 14:44:59 -0000
| Newsgroups | gmane.comp.php.cowiki.cvs |
|---|---|
| Message-ID | <[email protected]> |
User: dgorski Date: 2005/05/24 07:44:59 Modified: cowiki/htdocs/setup/installer.php Log: Honour "magic_quotes_gpc" and "stripslashes" if necessary Thanks SammyWG for pointing this out. File Changes: Directory: /cowiki/htdocs/setup/ ================================ File [changed]: installer.php Url: http://cowiki.tigris.org/source/browse/cowiki/htdocs/setup/installer.php?r1=1.4&r2=1.5 Delta lines: +93 -88 --------------------- --- installer.php 14 May 2005 21:12:54 -0000 1.4 +++ installer.php 24 May 2005 14:44:57 -0000 1.5 @@ -2,7 +2,7 @@ /** * - * $Id: installer.php,v 1.4 2005/05/14 21:12:54 dgorski Exp $ + * $Id: installer.php,v 1.5 2005/05/24 14:44:57 dgorski Exp $ * * This file is part of coWiki. coWiki is free software under the terms of * the GNU General Public License (GPL). Read the LICENSE file. If you did @@ -17,7 +17,7 @@ * @author Daniel T. Gorski, <[email protected]> * @copyright (C) Daniel T. Gorski, {@link http://www.develnet.org} * @license http://www.gnu.org/licenses/gpl.html - * @version $Revision: 1.4 $ + * @version $Revision: 1.5 $ * */ @@ -85,9 +85,14 @@ ob_start(); // Trim all posted data + // Working with ecaped values is annoying and confusing foreach($_POST as $k => $v) { + if (ini_get('magic_quotes_gpc')) { + $_POST[$k] = stripslashes(trim($v)); + } else { $_POST[$k] = trim($v); } + } // ----------------------------------------------------------------