ID: 19902 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Analyzed Bug Type: Scripting Engine problem Operating System: All Win PHP Version: 4.2.3 New Comment:
Hello Iliaa Thank you for acknowledging my initial "Suggestion". I do not recall exactly when I first came across a bundled browscap.ini with "not valid entries", but it must have been quite some time (php releases) ago. Probably browscap.ini is a static item in the bundling process and thus the invalid line 8206 got propagated with every (win) distribution. There does not seem to be a reason, why future releases of PHP should contain an uncorrected version of browscap.ini. Thanks again. Kind regards Juri Previous Comments: ------------------------------------------------------------------------ [2002-10-14 19:44:03] [EMAIL PROTECTED] Actually after checking it seems the Windows distribution contains a bundled browscap.ini file. My applogies. I'll look into why we are bundling this file and what can be done to correct it. ------------------------------------------------------------------------ [2002-10-14 19:35:26] [EMAIL PROTECTED] browscap.ini is NOT released by PHP, this file can be obtained from various sources on the net none of which are related to the PHP project. PHP merely has a generic ini parser that amongst other things can parse browscap.ini files. For whatever reason those files are not always completely compatible or properly formatted. Thus they sometimes cannot be parsed completely by the PHP's parser. This means that the incompatible lines should either be removed or altered. ------------------------------------------------------------------------ [2002-10-14 19:24:52] [EMAIL PROTECTED] Hello Iliaa Why do you release a browscap.ini with invalid entries with every new distribution of PHP? Everybody using browscap.ini is forced to edit it, before he may use it. Cumbersom... Kind regards Juri ------------------------------------------------------------------------ [2002-10-14 18:54:22] [EMAIL PROTECTED] Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php The browscap.ini sometimes contains not valid entries not supported by PHP's ini parser. Simply remove those lines, there are usually very few of those. ------------------------------------------------------------------------ [2002-10-14 10:38:13] [EMAIL PROTECTED] Hello Bug Report reader. <?php function list_array ($array) { while (list ($key, $value) = each ($array)) { $str .= "<b>$key:</b> $value<br>\n"; } return $str; } echo "$HTTP_USER_AGENT<hr>\n"; $browser = get_browser(); echo list_array ((array) $browser); ?> The browser information will be output together with the following message appended: PHP: Error parsing [drive]:\[path]\browscap.ini on line 8206 browscap.ini at line position 8206 reads: browser=AE/2.1(Linux) Changing "AE/2.1(Linux)" to "AE/2.1 Linux" solves the parsing error. The parsing procedure seems to "dislike" brackets [(,)]. This problem is quite old, but still persists with PHP 4.2.3. Suggestion: Update browscap.ini for PHP distributions accordingly. Kind regards Juri ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=19902&edit=1