note 56097 added to class.dir

From: Date: Tue, 23 Aug 2005 13:09:33 +0000
Subject: note 56097 added to class.dir
Groups: php.notes 
Request: Send a blank email to php-notes+get-94078@lists.php.net to get a copy of this message
instead of using a root path every time, you can use a real path to keep everything relative to each other. Like so <?php $real_path = realpath("../myfolder/"); $d = dir($real_path); echo "Handle: " . $d->handle . "\n"; echo "Path: " . $d->path . "\n"; while (false !== ($entry = $d->read())) { echo $entry."\n"; } $d->close(); ?> ---- Manual Page -- http://www.php.net/manual/en/class.dir.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+56097 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+56097&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+56097&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+56097&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+56097&report=yes&reason=useless Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+56097&report=yes&reason=non-english Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+56097&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+56097&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#94078) next »