#23422 [NEW]: $string1.$string2 does not always work properly

From: Date: Wed, 30 Apr 2003 02:01:14 +0000
Subject: #23422 [NEW]: $string1.$string2 does not always work properly
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-38781@lists.php.net to get a copy of this message
From: janez at pinkponk dot com Operating system: XP PHP version: 4.3.2RC2 PHP Bug Type: Filesystem function related Bug description: $string1.$string2 does not always work properly Short description: $string1='<?php '; $string2= fread( IE6.0 saved file from "Google Search: site:www.php.net rmdir" $string3=' ?>' $newstring=$string1.$string2.$string3 or newstring=implode($strings -from array) instead of $string1.$string2.$string3 I get the following: $string1.''.$string2.$string3 I don't know why there should be an '' in the file. A file saved IE6.0 from www.aljazeera.net works fine. And so do other files. I tried opening files both in ascii and binary-forced mode. It seems that there is a problem with string concatenation. Anyway, even if it's not a bug (I'm new to PHP), I would like to know how to circumvent it. Source code at http://www.janez.info/googlebug/ -- Edit bug report at http://bugs.php.net/?id=23422&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=23422&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=23422&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=23422&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=23422&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=23422&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=23422&r=support Expected behavior: http://bugs.php.net/fix.php?id=23422&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=23422&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=23422&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=23422&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=23422&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=23422&r=dst IIS Stability: http://bugs.php.net/fix.php?id=23422&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=23422&r=gnused

« previous php.bugs (#38781) next »