|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2003-08-18 09:54 UTC] courtois at nouvo dot com
[2003-08-18 14:08 UTC] helly@php.net
[2003-08-18 19:08 UTC] sniper@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Oct 28 07:00:01 2025 UTC |
Description: ------------ db3 open doesn't work with a path including directories. windows XP Apache 2 PHP 4.3.2 zip package [6,107Kb] - 29 May 2003 (from www.php.net) Reproduce code: --------------- <?php header('Content-type: text/plain'); mkdir("foobar",0755); print "testflat :"; if ($id = dba_open ("testflat", "n", "flatfile")) { print "ok\n"; dba_close ($id); } else print "not ok\n"; print "testdb3 :"; if ($id = dba_open ("testdb3", "n", "db3")) { print "ok\n"; dba_close ($id); } else print "not ok\n"; print "foobar/testflat :"; if ($id = dba_open ("foobar/testflat", "n", "flatfile")) { print "ok\n"; dba_close ($id); } else print "not ok\n"; print "foobar/testdb3"; if ($id = dba_open ("foobar/testdb3", "n", "db3")) { print "ok\n"; dba_close ($id); } else print "not ok\n"; chdir("foobar"); print "change to dir foobar\n"; print "foobar/testflat-cd :"; if ($id = dba_open ("testflat-cd", "n", "flatfile")) { print "ok\n"; dba_close ($id); } else print "not ok\n"; print "foobar/testdb3-cd :"; if ($id = dba_open ("testdb3-cd", "n", "db3")) { print "ok\n"; dba_close ($id); } else print "not ok\n"; ?> Expected result: ---------------- I expect foobar/testdb3 to be opened correctly. same result when / is replaced with \ Actual result: -------------- testflat :ok testdb3 :ok foobar/testflat :ok foobar/testdb3<br /> <b>Warning</b>: dba_open(foobar/testdb3,n): Driver initialization failed for handler: db3: No such file or directory in <b>C:\Program Files\Apache Group\Apache2\htdocs\testdba.php</b> on line <b>17</b><br /> not ok change to dir foobar foobar/testflat-cd :ok foobar/testdb3-cd :ok