|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-09-27 22:43 UTC] rickwalker2001 at gmail dot com
[2009-09-28 07:00 UTC] jani@php.net
[2009-09-28 07:30 UTC] rickwalker2001 at gmail dot com
[2009-09-28 11:59 UTC] rickwalker2001 at gmail dot com
[2009-09-28 12:47 UTC] jani@php.net
[2009-09-28 13:08 UTC] rickwalker2001 at gmail dot com
[2009-09-28 22:57 UTC] svn@php.net
[2009-09-29 13:42 UTC] rdohms@php.net
[2009-09-29 13:55 UTC] rickwalker2001 at gmail dot com
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 23:00:01 2025 UTC |
Description: ------------ When parsing ini files if the key contains a '/' char a syntax error is thrown. I have seen a bug closed as bogus from back in feb on one of the 5.3 beta versions but I am seeing this with the latest stable 5.3 build from macports. PHP 5.3.0 (cli) (built: Sep 26 2009 00:08:23) Copyright (c) 1997-2009 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies with Xdebug v2.0.5, Copyright (c) 2002-2008, by Derick Rethans Reproduce code: --------------- //my.ini file [sitemap] /home = default:index /info = default:info print_r(parse_ini_file('my.ini', true)); Expected result: ---------------- Array ( [sitemap] => Array ( [/home] => default:index [/info] => default:info ) ) Actual result: -------------- PHP Warning: syntax error, unexpected '/' in my.ini on line 2 in /Users/rick/test.php on line 5 PHP Stack trace: PHP 1. {main}() /Users/rick/test.php:0 PHP 2. parse_ini_file() /Users/rick/test.php:5 Warning: syntax error, unexpected '/' in my.ini on line 2 in /Users/rick/test.php on line 5 Call Stack: 0.0004 622136 1. {main}() /Users/rick/test.php:0 0.0004 622312 2. parse_ini_file() /Users/rick/test.php:5