note 68869 added to function.glob

From: Date: Mon, 14 Aug 2006 09:22:23 +0000
Subject: note 68869 added to function.glob
Groups: php.notes 
Request: Send a blank email to php-notes+get-115887@lists.php.net to get a copy of this message
The answer for the difference in the dirsize function of "management at twilightus dot net": glob('*') ignores all 'hidden' files by default. This means it does not return files that start with a dot (e.g. ".file"). If you want to match those files too, you can use "{,.}*" as the pattern with the GLOB_BRACE flag. <?php // Search for all files that match .* or * $files = glob('{,.}*', GLOB_BRACE); ?> Note: This also returns the directory special entries . and .. ---- Server IP: 217.160.72.57 Probable Submitter: 194.173.174.20 ---- X-Spam-Status: No, hits=3.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER autolearn=no version=2.64 ---- Manual Page -- http://www.php.net/manual/en/function.glob.php Edit -- https://master.php.net/note/edit/68869 Del: integrated -- https://master.php.net/note/delete/68869/integrated Del: useless -- https://master.php.net/note/delete/68869/useless Del: bad code -- https://master.php.net/note/delete/68869/bad+code Del: spam -- https://master.php.net/note/delete/68869/spam Del: non-english -- https://master.php.net/note/delete/68869/non-english Del: in docs -- https://master.php.net/note/delete/68869/in+docs Del: other reasons-- https://master.php.net/note/delete/68869 Reject -- https://master.php.net/note/reject/68869 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#115887) next »