Difference in parsing "{" inside control loops
| From: | Michal Kolodziejczyk | Date: | Sun, 12 Sep 1999 22:53:35 +0000 |
| Subject: | Difference in parsing "{" inside control loops | ||
| References: | 1 | Groups: | php.version4 |
| Request: | Send a blank email to php-version4+get-4372@lists.php.net to get a copy of this message | ||
Hello,
I am trying imp with php4.0b2, and I found out its not working because of
the following lines:
while(!is_object($structure) || !imap_ping($mbox)) {
$mbox = imap_open("{$server:$port}$mailbox", $user, $pass);
$structure = @imap_fetchstructure($mbox, imap_msgno($mbox, $index));
}
To make it working I had to add a backslash before "{" in the second line:
$mbox = imap_open("\{$server:$port}$mailbox", $user, $pass);
Is it expected behaviour? The braces are quoted and I think should not
affect the control loop. Looks like a bug to me. It did work for php3.
Michal
--
___
/ \ ___ Michal Kolodziejczyk Centrum Nowych Technologii
| |\ | | miko@cnt.pl Uphagena 2, 80-237 Gdansk
| | \| | tel/fax (58) 345 55 45
\ __/ ----------------- http://www.cnt.pl
----------------------