Bug #63835 [Opn->Csd]: two cookie in request ,get comma in first cookie name
Edit report at https://bugs.php.net/bug.php?id=63835&edit=1 ID: 63835 User updated by:tom916 at qq dot com Reported by:tom916 at qq dot com Summary:two cookie in request ,get comma in first cookie name -Status: Open +Status: Closed Type: Bug Package:*General Issues Operating System: linux PHP Version:5.3Git-2012-12-22 (Git) Block user comment: N Private report: N New Comment: Thank you very much to help me solve the problem in such a short time. Do you know why the browser will send the cookie header? Our website every day will receive nearly 10,000 such requests. Previous Comments: [2012-12-23 06:04:14] larue...@php.net The following patch has been added/updated: Patch Name: bug63835.patch Revision: 1356242654 URL: https://bugs.php.net/patch-display.php?bug=63835&patch=bug63835.patch&revision=1356242654 [2012-12-23 05:48:53] larue...@php.net oh, ignore my previous comment, apache return a comma separated string if there is multi cookie headers [2012-12-23 05:46:39] larue...@php.net I don't think it's a php specific bug, php read the cookie via apache apr_table_get apr_table_get return ", a=1" in your case. [2012-12-22 17:21:20] tom916 at qq dot com Description: When the browser client send 2 Cookie: in headerï¼the php get first cookie name has a comma in the fist charãGod know know the browser send 2 Cookie in header ? Array ( [,_a] => 1 ) Test script: --- --show_cookie.php-- \n"; } else { $out = "GET /show_cookie.php HTTP/1.1\r\n"; $out .= "Host: localhost:50080\r\n"; $out .= "Cookie:\r\n"; $out .= "Cookie: a=1\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); } php send_cookie.php -result--- HTTP/1.1 200 OK Date: Sat, 22 Dec 2012 17:11:59 GMT Server: Apache/2.2.17 (Unix) PHP/5.3.3 X-Powered-By: PHP/5.3.3 Content-Length: 25 Connection: close Content-Type: text/html Array ( [,_a] => 1 ) Expected result: Array ( [a] => 1 ) Actual result: -- Array ( [,_a] => 1 ) -- Edit this bug report at https://bugs.php.net/bug.php?id=63835&edit=1
Bug #63835 [Csd->Asn]: two cookie in request ,get comma in first cookie name
Edit report at https://bugs.php.net/bug.php?id=63835&edit=1 ID: 63835 User updated by:tom916 at qq dot com Reported by:tom916 at qq dot com Summary:two cookie in request ,get comma in first cookie name -Status: Closed +Status: Assigned Type: Bug Package:*General Issues Operating System: linux PHP Version:5.3Git-2012-12-22 (Git) Block user comment: N Private report: N New Comment: Now if the cookie name has a comma ,It becomes 2 cookie name \n"; } else { $out = "GET /show_cookie.php HTTP/1.1\r\n"; $out .= "Host: localhost:50080\r\n"; //$out .= "Cookie:\r\n"; $out .= "Cookie: a=1; b=2; c,d=abc\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); } Array ( [a] => 1 [b] => 2 [c] => [d] => abc ) Previous Comments: [2012-12-23 08:05:40] tom916 at qq dot com Thank you very much to help me solve the problem in such a short time. Do you know why the browser will send the cookie header? Our website every day will receive nearly 10,000 such requests. [2012-12-23 06:04:14] larue...@php.net The following patch has been added/updated: Patch Name: bug63835.patch Revision: 1356242654 URL: https://bugs.php.net/patch-display.php?bug=63835&patch=bug63835.patch&revision=1356242654 [2012-12-23 05:48:53] larue...@php.net oh, ignore my previous comment, apache return a comma separated string if there is multi cookie headers [2012-12-23 05:46:39] larue...@php.net I don't think it's a php specific bug, php read the cookie via apache apr_table_get apr_table_get return ", a=1" in your case. [2012-12-22 17:21:20] tom916 at qq dot com Description: When the browser client send 2 Cookie: in headerï¼the php get first cookie name has a comma in the fist charãGod know know the browser send 2 Cookie in header ? Array ( [,_a] => 1 ) Test script: --- --show_cookie.php-- \n"; } else { $out = "GET /show_cookie.php HTTP/1.1\r\n"; $out .= "Host: localhost:50080\r\n"; $out .= "Cookie:\r\n"; $out .= "Cookie: a=1\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); } php send_cookie.php -result--- HTTP/1.1 200 OK Date: Sat, 22 Dec 2012 17:11:59 GMT Server: Apache/2.2.17 (Unix) PHP/5.3.3 X-Powered-By: PHP/5.3.3 Content-Length: 25 Connection: close Content-Type: text/html Array ( [,_a] => 1 ) Expected result: Array ( [a] => 1 ) Actual result: -- Array ( [,_a] => 1 ) -- Edit this bug report at https://bugs.php.net/bug.php?id=63835&edit=1
Bug #44686 [Com]: SOAP-ERROR: Parsing WSDL
Edit report at https://bugs.php.net/bug.php?id=44686&edit=1 ID: 44686 Comment by: terenzio at tiscali dot it Reported by:dmittner at llnw dot com Summary:SOAP-ERROR: Parsing WSDL Status: Closed Type: Bug Package:SOAP related Operating System: Gentoo PHP Version:5.2.5 Assigned To:dmitry Block user comment: N Private report: N New Comment: Still getting SOAP-ERROR: Parsing Schema: unresolved element 'ref' attribute whith PHP 5.3.14 (cli) (built: Jun 19 2012 03:47:42) on CENTOS while parsing a WSDL containing Information about a telephone number, including the actual number and its usage. removing ref= and replacing with name= solves the problem but this fix cannot be applied on remote WSDL and leads to potentially invalid WSDL Previous Comments: [2012-07-24 23:38:54] ras...@php.net Automatic comment on behalf of dmitry Revision: http://git.php.net/?p=php-src.git;a=commit;h=52deaeb8c0dcba1322ac84b23831baa8f796f457 Log: Fixed bug #44686 (SOAP-ERROR: Parsing WSDL with references) [2012-04-18 09:47:48] larue...@php.net Automatic comment on behalf of dmitry Revision: http://git.php.net/?p=php-src.git;a=commit;h=52deaeb8c0dcba1322ac84b23831baa8f796f457 Log: Fixed bug #44686 (SOAP-ERROR: Parsing WSDL with references) [2011-11-18 01:28:42] mykel at xtreme dot com dot au just a heads up everyone: most of these issues can be resolved by changing to you will of course need to be using local WSDL/XSD files, which shouldn't be a problem for OTA requests. [2011-11-14 08:43:57] dmi...@php.net This bug has been fixed in SVN. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. For Windows: http://windows.php.net/snapshots/ Thank you for the report, and for helping us make PHP better. [2011-11-14 08:42:51] dmi...@php.net Automatic comment from SVN on behalf of dmitry Revision: http://svn.php.net/viewvc/?view=revision&revision=319151 Log: Fixed bug #44686 (SOAP-ERROR: Parsing WSDL with references) The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=44686 -- Edit this bug report at https://bugs.php.net/bug.php?id=44686&edit=1
Bug #62399 [Opn->Csd]: 404 link at author page of pecl web
Edit report at https://bugs.php.net/bug.php?id=62399&edit=1 ID: 62399 Updated by: m...@php.net Reported by:larue...@php.net Summary:404 link at author page of pecl web -Status: Open +Status: Closed Type: Bug Package:*General Issues PHP Version:Irrelevant -Assigned To: +Assigned To:mj Block user comment: N Private report: N New Comment: Fixed in git. Will be online after the next update cycle for peclweb. Previous Comments: [2012-06-23 09:22:26] larue...@php.net Description: http://pecl.php.net/user/jan the Net_Ping link is 404. -- Edit this bug report at https://bugs.php.net/bug.php?id=62399&edit=1
[PHP-BUG] Bug #63839 [NEW]: iconv_mime_decode_headers function is skipping headers
From: nidhikaushal28 at gmail dot com Operating system: Windows 7, CentOS PHP version: 5.3.20 Package: ICONV related Bug Type: Bug Bug description:iconv_mime_decode_headers function is skipping headers Description: iconv_mime_decode_headers function is skipping headers when '=?' is present in the subject. For example if the subject header of a mime message is : Subject: Reply Is? white side-LED =? in Help Then the rest of the headers after subject like content-type, date etc are not returned. Similar bug is filed https://bugs.php.net/bug.php?id=52941 but in the above mentioned example the subject is not encoded. My php version is 5.3.3 and the issue is reproducible in 5.3.20 and 5.4.10. Test script: --- To: Subject: Reply Is? white side-LED =? in Help Date: Sat, 22 Dec 2012 Message-ID: <006f01cde00e$d9f79da0$8de6d8e0> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="=_NextPart_000_0070_01CDE03C.F3AFD9A0" X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: Ac3gDtcH2huHjzYcQVmFJPPoWjJogA== Content-Language: en-us '; $headers = iconv_mime_decode_headers($headers, ICONV_MIME_DECODE_CONTINUE_ON_ERROR); print_r($headers); ?> Expected result: Array ( [From] => "xyz" [To] => [Subject] => Reply Is? white side-LED =? in Help [Date] => Sat, 22 Dec 2012 [Message-ID] => <006f01cde00e$d9f79da0$8de6d8e0> [MIME-Version] => 1.0 [Content-Type] => multipart/alternative; boundary="=_NextPart_000_0070_0 1CDE03C.F3AFD9A0" [X-Mailer] => Microsoft Office Outlook 12.0 [Thread-Index] => Ac3gDtcH2huHjzYcQVmFJPPoWjJogA== [Content-Language] => en-us ) Actual result: -- Array ( [From] => "xyz" [To] => [Subject] => Reply Is? white side-LED ) -- Edit bug report at https://bugs.php.net/bug.php?id=63839&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=63839&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=63839&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=63839&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=63839&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=63839&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=63839&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=63839&r=needscript Try newer version: https://bugs.php.net/fix.php?id=63839&r=oldversion Not developer issue:https://bugs.php.net/fix.php?id=63839&r=support Expected behavior: https://bugs.php.net/fix.php?id=63839&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=63839&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=63839&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=63839&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=63839&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=63839&r=dst IIS Stability: https://bugs.php.net/fix.php?id=63839&r=isapi Install GNU Sed:https://bugs.php.net/fix.php?id=63839&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=63839&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=63839&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=63839&r=mysqlcfg
[PHP-BUG] Bug #63840 [NEW]: preg_peplace crash
From: DuMOHsmol at yandex dot ru Operating system: Windows PHP version: 5.3Git-2012-12-23 (snap) Package: *Regular Expressions Bug Type: Bug Bug description:preg_peplace crash Description: Hello, this code crashes Apache with PHP on Windows. I know that this regex is not quite correct, but still. The solution is to increase Apache stack, but I think there should be some check in PHP to prevent crashing. Test script: --- $text = ' test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test '; $text = preg_replace('/([\n]|.)*/','test',$text); echo $text; -- Edit bug report at https://bugs.php.net/bug.php?id=63840&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=63840&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=63840&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=63840&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=63840&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=63840&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=63840&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=63840&r=needscript Try newer version: https://bugs.php.net/fix.php?id=63840&r=oldversion Not developer issue:https://bugs.php.net/fix.php?id=63840&r=support Expected behavior: https://bugs.php.net/fix.php?id=63840&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=63840&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=63840&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=63840&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=63840&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=63840&r=dst IIS Stability: https://bugs.php.net/fix.php?id=63840&r=isapi Install GNU Sed:https://bugs.php.net/fix.php?id=63840&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=63840&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=63840&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=63840&r=mysqlcfg
[PHP-BUG] Req #63841 [NEW]: Mind the constructor return value
From: paxcoder+phpnet at gmail dot com Operating system: PHP version: Irrelevant Package: Class/Object related Bug Type: Feature/Change Request Bug description:Mind the constructor return value Description: As-is, returning values in the constructor has no effect, and the class instance is returned instead. Either allow for explicitly returned values to supersede the object, or warn about trying to return a value from a constructor. Test script: --- Expected result: Either a warning at line 10, or $c set to NULL Actual result: -- No warning, and $c set to a C Object -- Edit bug report at https://bugs.php.net/bug.php?id=63841&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=63841&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=63841&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=63841&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=63841&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=63841&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=63841&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=63841&r=needscript Try newer version: https://bugs.php.net/fix.php?id=63841&r=oldversion Not developer issue:https://bugs.php.net/fix.php?id=63841&r=support Expected behavior: https://bugs.php.net/fix.php?id=63841&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=63841&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=63841&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=63841&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=63841&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=63841&r=dst IIS Stability: https://bugs.php.net/fix.php?id=63841&r=isapi Install GNU Sed:https://bugs.php.net/fix.php?id=63841&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=63841&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=63841&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=63841&r=mysqlcfg
Bug #63840 [Opn->Nab]: preg_peplace crash
Edit report at https://bugs.php.net/bug.php?id=63840&edit=1 ID: 63840 Updated by: fel...@php.net Reported by:DuMOHsmol at yandex dot ru Summary:preg_peplace crash -Status: Open +Status: Not a bug Type: Bug Package:*Regular Expressions Operating System: Windows PHP Version:5.3Git-2012-12-23 (snap) Block user comment: N Private report: N New Comment: See bug #63829 Previous Comments: [2012-12-23 16:19:04] DuMOHsmol at yandex dot ru Description: Hello, this code crashes Apache with PHP on Windows. I know that this regex is not quite correct, but still. The solution is to increase Apache stack, but I think there should be some check in PHP to prevent crashing. Test script: --- $text = ' test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test test_test_test_test_test_test_test_test_test_test_test_test_test_test_test '; $text = preg_replace('/([\n]|.)*/','test',$text); echo $text; -- Edit this bug report at https://bugs.php.net/bug.php?id=63840&edit=1
Req #60482 [Opn->Nab]: Add cookies to stream_context
Edit report at https://bugs.php.net/bug.php?id=60482&edit=1 ID: 60482 Updated by: m...@php.net Reported by:jille at hexon dot cx Summary:Add cookies to stream_context -Status: Open +Status: Not a bug Type: Feature/Change Request Package:Streams related Operating System: n/a PHP Version:Irrelevant Block user comment: N Private report: N New Comment: This can already be achieved using existing (albeit pretty low-level) functionality of the streams API: array( "method" => "GET", "header" => "Cookie: foo=bar", ) ); $context = stream_context_create($opts); $result = file_get_contents('http://example.com/server.php', false, $context); ?> Previous Comments: [2011-12-11 16:18:27] cataphr...@php.net It is trivial to add cookies by adding Cookie: headers. [2011-12-09 14:48:07] jille at hexon dot cx Description: I think cookies would be a usable addition to the possibilities of stream-context's. -- Edit this bug report at https://bugs.php.net/bug.php?id=60482&edit=1
Bug #63839 [Opn->Asn]: iconv_mime_decode_headers function is skipping headers
Edit report at https://bugs.php.net/bug.php?id=63839&edit=1 ID: 63839 Updated by: fel...@php.net Reported by:nidhikaushal28 at gmail dot com Summary:iconv_mime_decode_headers function is skipping headers -Status: Open +Status: Assigned Type: Bug Package:ICONV related Operating System: Windows 7, CentOS PHP Version:5.3.20 -Assigned To: +Assigned To:aharvey Block user comment: N Private report: N Previous Comments: [2012-12-23 14:48:08] nidhikaushal28 at gmail dot com Description: iconv_mime_decode_headers function is skipping headers when '=?' is present in the subject. For example if the subject header of a mime message is : Subject: Reply Is? white side-LED =? in Help Then the rest of the headers after subject like content-type, date etc are not returned. Similar bug is filed https://bugs.php.net/bug.php?id=52941 but in the above mentioned example the subject is not encoded. My php version is 5.3.3 and the issue is reproducible in 5.3.20 and 5.4.10. Test script: --- To: Subject: Reply Is? white side-LED =? in Help Date: Sat, 22 Dec 2012 Message-ID: <006f01cde00e$d9f79da0$8de6d8e0> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="=_NextPart_000_0070_01CDE03C.F3AFD9A0" X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: Ac3gDtcH2huHjzYcQVmFJPPoWjJogA== Content-Language: en-us '; $headers = iconv_mime_decode_headers($headers, ICONV_MIME_DECODE_CONTINUE_ON_ERROR); print_r($headers); ?> Expected result: Array ( [From] => "xyz" [To] => [Subject] => Reply Is? white side-LED =? in Help [Date] => Sat, 22 Dec 2012 [Message-ID] => <006f01cde00e$d9f79da0$8de6d8e0> [MIME-Version] => 1.0 [Content-Type] => multipart/alternative; boundary="=_NextPart_000_0070_0 1CDE03C.F3AFD9A0" [X-Mailer] => Microsoft Office Outlook 12.0 [Thread-Index] => Ac3gDtcH2huHjzYcQVmFJPPoWjJogA== [Content-Language] => en-us ) Actual result: -- Array ( [From] => "xyz" [To] => [Subject] => Reply Is? white side-LED ) -- Edit this bug report at https://bugs.php.net/bug.php?id=63839&edit=1
Bug #63823 [Opn]: SPL InfiniteIterator needs explicit rewind to be usable in a closure
Edit report at https://bugs.php.net/bug.php?id=63823&edit=1 ID: 63823 Updated by: fel...@php.net Reported by:s...@php.net Summary:SPL InfiniteIterator needs explicit rewind to be usable in a closure Status: Open Type: Bug Package:SPL related Operating System: Linux PHP Version:5.4Git-2012-12-21 (Git) Block user comment: N Private report: N New Comment: Are you referring to bug #44063? Previous Comments: [2012-12-21 02:35:41] larue...@php.net I saw similar report before, and remembered someone mark it as won't fix.. I just can not find the previous report now... [2012-12-21 02:20:57] s...@php.net A bigger example is: $val) { var_dump($val); } echo "\n'foreach' on InfiniteIterator\n"; $a = array('one', 'two', 'three'); $a_it = new InfiniteIterator(new ArrayIterator($a)); $i = 0; foreach ($a_it as $key => $val) { if ($i++ >= 7) break; var_dump($val); } echo "\n'for' on ArrayIterator\n"; $d = array('one', 'two', 'three'); $d_it = new ArrayIterator($d); for ($i = 0; $i < 3; $i++) { var_dump($d_it->current()); $d_it->next(); } echo "\n'for' on InfiniteIterator\n"; $b = array('one', 'two', 'three'); $b_it = new InfiniteIterator(new ArrayIterator($b)); for ($i = 0; $i < 7; $i++) { var_dump($b_it->current()); $b_it->next(); } ?> This outputs: 'foreach' on ArrayIterator string(3) "one" string(3) "two" string(5) "three" 'foreach' on InfiniteIterator string(3) "one" string(3) "two" string(5) "three" string(3) "one" string(3) "two" string(5) "three" string(3) "one" 'for' on ArrayIterator string(3) "one" string(3) "two" string(5) "three" 'for' on InfiniteIterator NULL string(3) "two" string(5) "three" string(3) "one" string(3) "two" string(5) "three" string(3) "one" So the odd behavior is with the last loop. A "real" life script (from discussion on php.internals) is: rewind(); // why is the rewind needed? $result = preg_replace_callback( '/word/', function($matches) use ($replacements_iterator) { $r = $replacements_iterator->current(); $replacements_iterator->next(); return $r; }, 'word word word word word' ); var_dump($result); // Outputs: //string(21) "one two three one two" // Without the call to $replacements_iterator->rewind(), the output is: //string(18) " two three one two" ?> [2012-12-21 02:17:17] s...@php.net Description: SPL's InfiniteIterator returns NULL for the first access, unless used in a 'foreach' loop, or a rewind is done. This means that an explicit rewind is needed before an InfiniteIterator can be safely be used in an application. Test script: --- current()); $b_it->next(); } ?> Expected result: string(3) "one" string(3) "two" string(5) "three" string(3) "one" string(3) "two" string(5) "three" string(3) "one" Actual result: -- NULL string(3) "two" string(5) "three" string(3) "one" string(3) "two" string(5) "three" string(3) "one" -- Edit this bug report at https://bugs.php.net/bug.php?id=63823&edit=1
Bug #63813 [Opn->Nab]: FETCH_GROUP Does not work with FETCH_KEY_PAIR
Edit report at https://bugs.php.net/bug.php?id=63813&edit=1 ID: 63813 Updated by: fel...@php.net Reported by:contact at joycebabu dot com Summary:FETCH_GROUP Does not work with FETCH_KEY_PAIR -Status: Open +Status: Not a bug Type: Bug Package:PDO related PHP Version:Irrelevant Block user comment: N Private report: N New Comment: Your query must be only "SELECT location, name FROM employees" Previous Comments: [2012-12-20 07:56:36] contact at joycebabu dot com Description: Documentation for PDO::FETCH_GROUP says "Group return by values. Usually combined with PDO::FETCH_COLUMN or PDO::FETCH_KEY_PAIR." But FETCH_GROUP does not work with FETCH_KEY_PAIR. When three columns are specified in the query, the fetch fails with the erorr message "Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: PDO::FETCH_KEY_PAIR fetch mode requires the result set to contain extactly 2 columns." When 2 columns are specified in the query, the fetch returns an associative array with only one value for each unique grouped key, which is useless. Test script: --- /* employee table | location | emp_id | name | | New York | 1 | John | | New York | 2 | Jane | | London | 3 | Jack | | London | 4 | Nick | */ $db->query('SELECT location, emp_id, name FROM employees'); $employees = $db->fetchAll(PDO::FETCH_GROUP | PDO::FETCH_KEY_PAIR); Expected result: array( 'New York' => array( 1 => 'John', 2 => 'Jane' ), 'London' => array( 3 => 'Jack', 4 => 'Nick' ) ) Actual result: -- array( 'New York' => 'Jane', 'London' => 'Nick' ) -- Edit this bug report at https://bugs.php.net/bug.php?id=63813&edit=1
Bug #63809 [Opn->Asn]: ORA-01461 when inserting/updating more that 1333 characters
Edit report at https://bugs.php.net/bug.php?id=63809&edit=1 ID: 63809 Updated by: fel...@php.net Reported by:blair dot chesnut at gmail dot com Summary:ORA-01461 when inserting/updating more that 1333 characters -Status: Open +Status: Assigned Type: Bug Package:PDO related Operating System: Unix/Solaris 10 PHP Version:5.4.9 -Assigned To: +Assigned To:sixd Block user comment: N Private report: N Previous Comments: [2012-12-19 19:42:49] blair dot chesnut at gmail dot com Description: Using PDO/OCI via Yii framework. Inserts/updates to varchar2(4000) column fail with error ORA-01461 when value exceeds 1332 characters. Line 300 of source php-5.4.9/ext/pdo_oci/oci_statement.c: value_sz = 1332; /* maximum size before value is interpreted as a LONG value */ Why??? I changed to "value_sz = 4000", recompiled, and inserts/updates work fine. I'm not using CLOBs, only varchar2() columns. Test script: --- $dbh = new PDO($dsn, $dbuser, $dbpass); $sth = $dbh->prepare('insert into some_table (some_varchar4000_column) values (:p1)'); $big_value = str_repeat('ABCDEFGHIJ', 300); $sth->bindValue(':p1', $big_value, PDO::PARAM_STR); $sth->execute(); print_r($sth->errorInfo()); Expected result: Array ( [0] => 0 [1] => [2] => ) Actual result: -- Array ( [0] => HY000 [1] => 1461 [2] => OCIStmtExecute: ORA-01461: can bind a LONG value only for insert into a LONG column (/usr/local/src/php-5.4.5/ext/pdo_oci/oci_statement.c:146) ) -- Edit this bug report at https://bugs.php.net/bug.php?id=63809&edit=1
Bug #63784 [Opn]: var_export() produces EOL symbols irregardless of target OS
Edit report at https://bugs.php.net/bug.php?id=63784&edit=1 ID: 63784 Updated by: fel...@php.net Reported by:hayk at mail dot ru Summary:var_export() produces EOL symbols irregardless of target OS Status: Open Type: Bug Package:*General Issues Operating System: Windows XP PHP Version:5.4.9 Block user comment: N Private report: N New Comment: Actually it is not only var_export(), var_dump() also uses hardcoded LF. Previous Comments: [2012-12-16 23:25:05] hayk at mail dot ru Description: var_export() produces EOL symbols irregardless of target OS. It's always "\n" even on Windows. Test script: --- 1); echo var_export($a, true); echo strlen(var_export($a, true)); ?> Expected result: array ( 'a' => 1, )23 Actual result: -- array ( 'a' => 1, )21 -- Edit this bug report at https://bugs.php.net/bug.php?id=63784&edit=1
Bug #63782 [Opn->Nab]: php.ini not loaded by php-fpm unless -c switch is used
Edit report at https://bugs.php.net/bug.php?id=63782&edit=1 ID: 63782 Updated by: fel...@php.net Reported by:infected817 at gmail dot com Summary:php.ini not loaded by php-fpm unless -c switch is used -Status: Open +Status: Not a bug Type: Bug Package:*Configuration Issues Operating System: Ubuntu Desktop 12.10 PHP Version:5.4.9 Block user comment: N Private report: N New Comment: Already exists a hint which does not uses trailing slash. " --with-config-file-path=PATH Set the path in which to look for php.ini [PREFIX/lib]" Previous Comments: [2012-12-17 03:35:20] infected817 at gmail dot com Mystery solved. I recompiled PHP with this configuration flag: --with-config-file-path=/etc/php5 Notice that before, I used --with-config-file-path=/etc/php5/ The trailing slash seems to be causing problems. I think it would be helpful to do the following: - Fix PHP to accept configuration folders with or without the trailing slash. OR - Add a note for --with-config-file-path in ./configure --help that says the trailing slash should be omitted. [2012-12-17 02:52:05] larue...@php.net make sure that you have did "make clean" after you re-configure [2012-12-17 02:30:29] infected817 at gmail dot com Clarified php.ini location. [2012-12-16 22:28:53] infected817 at gmail dot com Hi there, I actually made a mistake when copying the contents of the phpinfo() output as I had 2 virtual machines running at the time. My apologies for that. I just checked again and these are the results: Ubuntu Desktop 12.10 Configuration File (php.ini) Path /etc/php5/ Loaded Configuration File (none) However, there is a valid php.ini in /etc/php5 that is not being loaded. Is there anything else/more information I can check/provide? [2012-12-16 10:58:27] re...@php.net It's compiled with: /etc/php5/fpm Configuration File (php.ini) Path */etc/php5/[fpm]* Loaded Configuration File (none) but you try to load php.ini from: /etc/php5 <-- no fpm it's different. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=63782 -- Edit this bug report at https://bugs.php.net/bug.php?id=63782&edit=1
Bug #63724 [Opn->Nab]: MessageFormatter buggy when using select formats with nested parameters
Edit report at https://bugs.php.net/bug.php?id=63724&edit=1 ID: 63724 Updated by: fel...@php.net Reported by:eskwayrd at gmail dot com Summary:MessageFormatter buggy when using select formats with nested parameters -Status: Open +Status: Not a bug Type: Bug Package:I18N and L10N related Operating System: Linux PHP Version:5.4.9 Block user comment: N Private report: N New Comment: If it's really a problem, it occurred on ICU. See a related bug #62673 Using "{1, select, k {{0, number} kB} M {{0, number, #.##} MB} other {{0, number} B}}" does the job, somehow just like suggested in the bug I pointed out above. Previous Comments: [2012-12-07 23:11:49] eskwayrd at gmail dot com Description: When a message formatter formats selects with nested variables, its behaviour is buggy. Test script: --- // attempting to translate file size $locale = 'en_US'; $args = array(1.23435, 'M'); $format = "{1, select, k {{0} kB} M {{0} MB} other {{0} B}}"; echo "#1: ". msgfmt_format_message($locale, $format, $args) ."\n"; $format = "{1, select, k {{0} kB} M {{0, number, #.##} MB} other {{0} B}}"; echo "#2: ". msgfmt_format_message($locale, $format, $args) ."\n"; echo "Error? ". intl_get_error_message() ."\n"; Expected result: #1: 1.23435 MB #2: 1.23 MB Error? U_ZERO_ERROR Actual result: -- #1: 1.23435 MB #2: Error? Creating message formatter failed: U_ARGUMENT_TYPE_MISMATCH -- Edit this bug report at https://bugs.php.net/bug.php?id=63724&edit=1
Bug #53326 [Nab]: [IGNORE] Testing
Edit report at https://bugs.php.net/bug.php?id=53326&edit=1 ID: 53326 Updated by: fel...@php.net Reported by:felipensp at gmail dot com Summary:[IGNORE] Testing Status: Not a bug Type: Bug Package:Unknown/Other Function PHP Version:Irrelevant Block user comment: N Private report: N New Comment: Testing... related to bug #55087 Previous Comments: [2011-11-18 11:17:55] fel...@php.net . [2011-06-30 09:08:07] fel...@php.net test [2011-06-30 09:05:36] fel...@php.net This bug has been fixed in SVN. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. Thank you for the report, and for helping us make PHP better. [2011-06-30 08:53:19] fel...@php.net test [2011-04-21 19:27:47] felipensp at gmail dot com test The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=53326 -- Edit this bug report at https://bugs.php.net/bug.php?id=53326&edit=1
Bug #63809 [Asn->Opn]: ORA-01461 when inserting/updating more that 1333 characters
Edit report at https://bugs.php.net/bug.php?id=63809&edit=1 ID: 63809 Updated by: s...@php.net Reported by:blair dot chesnut at gmail dot com Summary:ORA-01461 when inserting/updating more that 1333 characters -Status: Assigned +Status: Open Type: Bug Package:PDO related Operating System: Unix/Solaris 10 PHP Version:5.4.9 -Assigned To:sixd +Assigned To: Block user comment: N Private report: N New Comment: See also https://bugs.php.net/bug.php?id=54379 value_sz is set to allow for character set conversion due to different client and server character sets. This might increase the storage requirements when the data is stored in the server. The hardcoded choice of the ratio is questionable. Previous Comments: [2012-12-19 19:42:49] blair dot chesnut at gmail dot com Description: Using PDO/OCI via Yii framework. Inserts/updates to varchar2(4000) column fail with error ORA-01461 when value exceeds 1332 characters. Line 300 of source php-5.4.9/ext/pdo_oci/oci_statement.c: value_sz = 1332; /* maximum size before value is interpreted as a LONG value */ Why??? I changed to "value_sz = 4000", recompiled, and inserts/updates work fine. I'm not using CLOBs, only varchar2() columns. Test script: --- $dbh = new PDO($dsn, $dbuser, $dbpass); $sth = $dbh->prepare('insert into some_table (some_varchar4000_column) values (:p1)'); $big_value = str_repeat('ABCDEFGHIJ', 300); $sth->bindValue(':p1', $big_value, PDO::PARAM_STR); $sth->execute(); print_r($sth->errorInfo()); Expected result: Array ( [0] => 0 [1] => [2] => ) Actual result: -- Array ( [0] => HY000 [1] => 1461 [2] => OCIStmtExecute: ORA-01461: can bind a LONG value only for insert into a LONG column (/usr/local/src/php-5.4.5/ext/pdo_oci/oci_statement.c:146) ) -- Edit this bug report at https://bugs.php.net/bug.php?id=63809&edit=1
Bug #63835 [Asn]: two cookie in request ,get comma in first cookie name
Edit report at https://bugs.php.net/bug.php?id=63835&edit=1 ID: 63835 Updated by: larue...@php.net Reported by:tom916 at qq dot com Summary:two cookie in request ,get comma in first cookie name Status: Assigned Type: Bug Package:*General Issues Operating System: linux PHP Version:5.3Git-2012-12-22 (Git) Assigned To:laruence Block user comment: N Private report: N New Comment: I have no idea why some browser will do this, but I can not find a proof that doesn't allow this. anyway, this fix will introduce bc break, like, before, cookie: userids=123,1232,123213; I saw such usage before, so... I didn't commit this. I will try to find some fix in the apache apis Previous Comments: [2012-12-23 08:52:49] tom916 at qq dot com Now if the cookie name has a comma ,It becomes 2 cookie name \n"; } else { $out = "GET /show_cookie.php HTTP/1.1\r\n"; $out .= "Host: localhost:50080\r\n"; //$out .= "Cookie:\r\n"; $out .= "Cookie: a=1; b=2; c,d=abc\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); } Array ( [a] => 1 [b] => 2 [c] => [d] => abc ) [2012-12-23 08:05:40] tom916 at qq dot com Thank you very much to help me solve the problem in such a short time. Do you know why the browser will send the cookie header? Our website every day will receive nearly 10,000 such requests. [2012-12-23 06:04:14] larue...@php.net The following patch has been added/updated: Patch Name: bug63835.patch Revision: 1356242654 URL: https://bugs.php.net/patch-display.php?bug=63835&patch=bug63835.patch&revision=1356242654 [2012-12-23 05:48:53] larue...@php.net oh, ignore my previous comment, apache return a comma separated string if there is multi cookie headers [2012-12-23 05:46:39] larue...@php.net I don't think it's a php specific bug, php read the cookie via apache apr_table_get apr_table_get return ", a=1" in your case. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=63835 -- Edit this bug report at https://bugs.php.net/bug.php?id=63835&edit=1
Bug #63835 [Asn]: two cookie in request ,get comma in first cookie name
Edit report at https://bugs.php.net/bug.php?id=63835&edit=1 ID: 63835 Updated by: pierr...@php.net Reported by:tom916 at qq dot com Summary:two cookie in request ,get comma in first cookie name Status: Assigned Type: Bug Package:*General Issues Operating System: linux PHP Version:5.3Git-2012-12-22 (Git) Assigned To:laruence Block user comment: N Private report: N New Comment: RFC2616 says : Multiple message-header fields with the same field-name MAY be present in a message if and only if the entire field-value for that header field is defined as a comma-separated list [i.e., #(values)]. It MUST be possible to combine the multiple header fields into one "field-name: field-value" pair, without changing the semantics of the message, by appending each subsequent field-value to the first, each separated by a comma. The order in which header fields with the same field-name are received is therefore significant to the interpretation of the combined field value, and thus a proxy MUST NOT change the order of these field values when a message is forwarded. Previous Comments: [2012-12-24 03:33:59] larue...@php.net I have no idea why some browser will do this, but I can not find a proof that doesn't allow this. anyway, this fix will introduce bc break, like, before, cookie: userids=123,1232,123213; I saw such usage before, so... I didn't commit this. I will try to find some fix in the apache apis [2012-12-23 08:52:49] tom916 at qq dot com Now if the cookie name has a comma ,It becomes 2 cookie name \n"; } else { $out = "GET /show_cookie.php HTTP/1.1\r\n"; $out .= "Host: localhost:50080\r\n"; //$out .= "Cookie:\r\n"; $out .= "Cookie: a=1; b=2; c,d=abc\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); } Array ( [a] => 1 [b] => 2 [c] => [d] => abc ) [2012-12-23 08:05:40] tom916 at qq dot com Thank you very much to help me solve the problem in such a short time. Do you know why the browser will send the cookie header? Our website every day will receive nearly 10,000 such requests. [2012-12-23 06:04:14] larue...@php.net The following patch has been added/updated: Patch Name: bug63835.patch Revision: 1356242654 URL: https://bugs.php.net/patch-display.php?bug=63835&patch=bug63835.patch&revision=1356242654 [2012-12-23 05:48:53] larue...@php.net oh, ignore my previous comment, apache return a comma separated string if there is multi cookie headers The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=63835 -- Edit this bug report at https://bugs.php.net/bug.php?id=63835&edit=1
Bug #63835 [Asn]: two cookie in request ,get comma in first cookie name
Edit report at https://bugs.php.net/bug.php?id=63835&edit=1 ID: 63835 Updated by: larue...@php.net Reported by:tom916 at qq dot com Summary:two cookie in request ,get comma in first cookie name Status: Assigned Type: Bug Package:*General Issues Operating System: linux PHP Version:5.3Git-2012-12-22 (Git) Assigned To:laruence Block user comment: N Private report: N New Comment: @pierrick, thanks, I also found a page: http://kristol.org/cookie/errata.html ;) Previous Comments: [2012-12-24 03:59:38] pierr...@php.net RFC2616 says : Multiple message-header fields with the same field-name MAY be present in a message if and only if the entire field-value for that header field is defined as a comma-separated list [i.e., #(values)]. It MUST be possible to combine the multiple header fields into one "field-name: field-value" pair, without changing the semantics of the message, by appending each subsequent field-value to the first, each separated by a comma. The order in which header fields with the same field-name are received is therefore significant to the interpretation of the combined field value, and thus a proxy MUST NOT change the order of these field values when a message is forwarded. [2012-12-24 03:33:59] larue...@php.net I have no idea why some browser will do this, but I can not find a proof that doesn't allow this. anyway, this fix will introduce bc break, like, before, cookie: userids=123,1232,123213; I saw such usage before, so... I didn't commit this. I will try to find some fix in the apache apis [2012-12-23 08:52:49] tom916 at qq dot com Now if the cookie name has a comma ,It becomes 2 cookie name \n"; } else { $out = "GET /show_cookie.php HTTP/1.1\r\n"; $out .= "Host: localhost:50080\r\n"; //$out .= "Cookie:\r\n"; $out .= "Cookie: a=1; b=2; c,d=abc\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); } Array ( [a] => 1 [b] => 2 [c] => [d] => abc ) [2012-12-23 08:05:40] tom916 at qq dot com Thank you very much to help me solve the problem in such a short time. Do you know why the browser will send the cookie header? Our website every day will receive nearly 10,000 such requests. [2012-12-23 06:04:14] larue...@php.net The following patch has been added/updated: Patch Name: bug63835.patch Revision: 1356242654 URL: https://bugs.php.net/patch-display.php?bug=63835&patch=bug63835.patch&revision=1356242654 The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=63835 -- Edit this bug report at https://bugs.php.net/bug.php?id=63835&edit=1
Bug #63835 [Asn]: two cookie in request ,get comma in first cookie name
Edit report at https://bugs.php.net/bug.php?id=63835&edit=1 ID: 63835 Updated by: pierr...@php.net Reported by:tom916 at qq dot com Summary:two cookie in request ,get comma in first cookie name Status: Assigned Type: Bug Package:*General Issues Operating System: linux PHP Version:5.3Git-2012-12-22 (Git) Assigned To:laruence Block user comment: N Private report: N New Comment: RFC6265 is the last specification for HTTP State Management Mechanism. Section 4.2.1 says that the grammar for the Cookie header is cookie-header = "Cookie:" OWS cookie-string OWS cookie-string = cookie-pair *( ";" SP cookie-pair ) Since RFC2626 (HTTP) only allows multiple message-header fields with the same if and only if the entire field-value for that header field is defined as a comma-separated list, I guess having multiple Cookie: header is not a valid case. Previous Comments: [2012-12-24 04:02:21] larue...@php.net @pierrick, thanks, I also found a page: http://kristol.org/cookie/errata.html ;) [2012-12-24 03:59:38] pierr...@php.net RFC2616 says : Multiple message-header fields with the same field-name MAY be present in a message if and only if the entire field-value for that header field is defined as a comma-separated list [i.e., #(values)]. It MUST be possible to combine the multiple header fields into one "field-name: field-value" pair, without changing the semantics of the message, by appending each subsequent field-value to the first, each separated by a comma. The order in which header fields with the same field-name are received is therefore significant to the interpretation of the combined field value, and thus a proxy MUST NOT change the order of these field values when a message is forwarded. [2012-12-24 03:33:59] larue...@php.net I have no idea why some browser will do this, but I can not find a proof that doesn't allow this. anyway, this fix will introduce bc break, like, before, cookie: userids=123,1232,123213; I saw such usage before, so... I didn't commit this. I will try to find some fix in the apache apis [2012-12-23 08:52:49] tom916 at qq dot com Now if the cookie name has a comma ,It becomes 2 cookie name \n"; } else { $out = "GET /show_cookie.php HTTP/1.1\r\n"; $out .= "Host: localhost:50080\r\n"; //$out .= "Cookie:\r\n"; $out .= "Cookie: a=1; b=2; c,d=abc\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); } Array ( [a] => 1 [b] => 2 [c] => [d] => abc ) [2012-12-23 08:05:40] tom916 at qq dot com Thank you very much to help me solve the problem in such a short time. Do you know why the browser will send the cookie header? Our website every day will receive nearly 10,000 such requests. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=63835 -- Edit this bug report at https://bugs.php.net/bug.php?id=63835&edit=1
Bug #63835 [Asn]: two cookie in request ,get comma in first cookie name
Edit report at https://bugs.php.net/bug.php?id=63835&edit=1 ID: 63835 Updated by: larue...@php.net Reported by:tom916 at qq dot com Summary:two cookie in request ,get comma in first cookie name Status: Assigned Type: Bug Package:*General Issues Operating System: linux PHP Version:5.3Git-2012-12-22 (Git) Assigned To:laruence Block user comment: N Private report: N New Comment: @pierrick , thanks for the explaination, and after some search, I also reached that we can not fix this without any side-affect(BC break), so, I think maybe won't fix. thanks Previous Comments: [2012-12-24 04:39:43] pierr...@php.net RFC6265 is the last specification for HTTP State Management Mechanism. Section 4.2.1 says that the grammar for the Cookie header is cookie-header = "Cookie:" OWS cookie-string OWS cookie-string = cookie-pair *( ";" SP cookie-pair ) Since RFC2626 (HTTP) only allows multiple message-header fields with the same if and only if the entire field-value for that header field is defined as a comma-separated list, I guess having multiple Cookie: header is not a valid case. [2012-12-24 04:02:21] larue...@php.net @pierrick, thanks, I also found a page: http://kristol.org/cookie/errata.html ;) [2012-12-24 03:59:38] pierr...@php.net RFC2616 says : Multiple message-header fields with the same field-name MAY be present in a message if and only if the entire field-value for that header field is defined as a comma-separated list [i.e., #(values)]. It MUST be possible to combine the multiple header fields into one "field-name: field-value" pair, without changing the semantics of the message, by appending each subsequent field-value to the first, each separated by a comma. The order in which header fields with the same field-name are received is therefore significant to the interpretation of the combined field value, and thus a proxy MUST NOT change the order of these field values when a message is forwarded. [2012-12-24 03:33:59] larue...@php.net I have no idea why some browser will do this, but I can not find a proof that doesn't allow this. anyway, this fix will introduce bc break, like, before, cookie: userids=123,1232,123213; I saw such usage before, so... I didn't commit this. I will try to find some fix in the apache apis [2012-12-23 08:52:49] tom916 at qq dot com Now if the cookie name has a comma ,It becomes 2 cookie name \n"; } else { $out = "GET /show_cookie.php HTTP/1.1\r\n"; $out .= "Host: localhost:50080\r\n"; //$out .= "Cookie:\r\n"; $out .= "Cookie: a=1; b=2; c,d=abc\r\n"; $out .= "Connection: Close\r\n\r\n"; fwrite($fp, $out); while (!feof($fp)) { echo fgets($fp, 128); } fclose($fp); } Array ( [a] => 1 [b] => 2 [c] => [d] => abc ) The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=63835 -- Edit this bug report at https://bugs.php.net/bug.php?id=63835&edit=1
Req #62614 [Opn]: Please update PCRE library to latest version
Edit report at https://bugs.php.net/bug.php?id=62614&edit=1 ID: 62614 User updated by:danielklein at airpost dot net Reported by:danielklein at airpost dot net Summary:Please update PCRE library to latest version Status: Open Type: Feature/Change Request Package:PCRE related -PHP Version:5.4.5 +PHP Version:5.4.9 Block user comment: N Private report: N New Comment: Thank you to all the people who helped get PCRE 8.31 into PHP 5.4.9 (& 5.3.19)! Now that PCRE 8.32 has been released, can that make its way into PHP too please? Main improvement (from user comments on previous request) - \X matches a Unicode extended grapheme cluster Thank you again! Previous Comments: [2012-07-20 00:20:57] danielklein at airpost dot net Description: PCRE Library Version is 8.12 (15-Jan-2011) as of PHP 5.4.5 (18-Jul-2012). Latest PCRE Library Version is 8.30 (04-Feb-2012). Please update PHP as there have been many improvements. -- Edit this bug report at https://bugs.php.net/bug.php?id=62614&edit=1
Req #54223 [Com]: enhance / change newline behavior
Edit report at https://bugs.php.net/bug.php?id=54223&edit=1 ID: 54223 Comment by: danielklein at airpost dot net Reported by:carsten_sttgt at gmx dot de Summary:enhance / change newline behavior Status: Open Type: Feature/Change Request Package:PCRE related PHP Version:Irrelevant Block user comment: N Private report: N New Comment: This is very old, well defined behaviour. /$/ matches /(?=\n?(?![\w\W]))/, that is a just before a newline with no remaining characters or end-of-string (no more characters). What you are asking for is /(?=\r?\n?(?![\w\W]))/ (or /$/m => /(?=\r\n?|\n)/) unless you're asking for ONLY \r\n to match! This would also have to change the meaning of /./ (without /s) from /[^\n]/ to /[^\r\n]/. This would be confusing for people used to the old way of doing things. Would this mean that /^/m would match just after a \r? (but not in between a \r and a \n???) It would be better to specify what you are matching or not matching rather than changing the behaviour of carriage returns. I agree this can make regexes more difficult to write and understand in some instances but I would vote to stay with the status quo as I believe adding such an option would add to the total confusion rather than decrease it. If you write /[^\r\n]+/ it is perfectly clear to anyone who understands character classes. Note that the difference between /.+/ and /.+/s is already subtle and easily missed. Another alternative is str_replace("\r\n", "\n", $input) before using the regex which will convert Windows style line endings to Unix style line endings. Previous Comments: [2011-03-11 11:23:30] carsten_sttgt at gmx dot de Description: At the moment (PHP bundled) PCRE is build with the default "#define NEWLINE 10". As a result "$" means "\n" but not e.g. "\r\n" and "\r" remains as part of the match. This is unexpected for some people, especially on Windows. See the example below. There are 3 solutions: 1) Building PCRE with "#define NEWLINE -2", or with "#define NEWLINE -1" (because PCRE is still build with Unicode support) 2) Adding a INI option like "pcre.newline=any" 3) Making PCRE_NEWLINE_ANY, PCRE_NEWLINE_CR, PCRE_NEWLINE_CRLF, PCRE_NEWLINE_LF available to the userland (maybe as pattern modifier), like you can do this with C using the PCRE library. (Well, 1) is not essential if 2) and 3) is available) Test script: --- Expected result: array(1) { [0]=> array(3) { [0]=> string(5) "line1" [1]=> string(5) "line2" [2]=> string(5) "line3" } } Actual result: -- array(1) { [0]=> array(3) { [0]=> " string(6) "line1 [1]=> " string(6) "line2 [2]=> " string(6) "line3 } } -- Edit this bug report at https://bugs.php.net/bug.php?id=54223&edit=1
Bug #44383 [Opn->Fbk]: PHP DateTime not converted to xsd:datetime
Edit report at https://bugs.php.net/bug.php?id=44383&edit=1 ID: 44383 Updated by: m...@php.net Reported by:kevin dot craft at gmail dot com Summary:PHP DateTime not converted to xsd:datetime -Status: Open +Status: Feedback Type: Bug Package:SOAP related Operating System: * PHP Version:5.*, 6 (2009-08-07 -Assigned To: +Assigned To:mj Block user comment: N Private report: N New Comment: David, I applied your patch to 5.6.0-dev but all the new tests are failing due to empty responses from SoapServer. Do you have some cycles to look into this? Previous Comments: [2012-05-03 10:33:48] andyidol at gmail dot com Please fix this! I beg you ) [2012-01-25 19:44:20] frozenf...@php.net I've encountered this issue today, and it would be really wonderful to have this patch applied. [2010-10-18 17:43:04] aldekein at myevil dot info It still does not work after 2.5 years in PHP 5.3.1 on Windows. Maybe this patch should be applied to official PHP branch? [2009-08-07 15:23:57] david dot zuelke at bitextender dot com Updated patch and tests: http://pastie.org/575559 [2009-06-29 08:56:29] lsm...@php.net Reopening since we now have a patch. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=44383 -- Edit this bug report at https://bugs.php.net/bug.php?id=44383&edit=1