note 22042 added to control-structures
| From: | m dot ernst at connect-wa dot de | Date: | Tue, 04 Jun 2002 18:39:46 +0000 |
| Subject: | note 22042 added to control-structures | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-31439@lists.php.net to get a copy of this message | ||
Hm, that just does NOT work at me:
if (is_file($source) &! is_file($target) &! copy($source, $dest)){
echo("erroro copyin file $source to $dest");
}
I thought that the logical test would stop immediately if one of the parameters would make the whole
phrase evaluate to false. I.e. if $source is not a file or if $dest already exists. But I got a
warning, that $source couldn't be opened for reading (when trying to copy it): "no such
file".
Martin
--
http://www.php.net/manual/en/control-structures.php
http://master.php.net/manage/user-notes.php?action=edit+22042
http://master.php.net/manage/user-notes.php?action=delete+22042
http://master.php.net/manage/user-notes.php?action=reject+22042