eAuction
  Not just another Perl script
Google
Welcome, Guest. Please Login or Register


If you use eAuction a lot and like it or if you make money from eAuction or from eAuction-related activities ...
then the project asks you for a donation in favor of the further development.



The forums are protected by
AccessControl
(written by Dieter Werner)
Click here if you want to check your IP against the most important RBLs of the net.
Click here in order to visite the AccessControl forums.


<< Visit the international e Auction Marketplace >>
Buy and sell PC and Consumer Electronic components






  HomeHelpSearchLoginRegister
 



Pages: 1 2 3 
readdir: file order (Read 1389 times)
Dieter Werner
Administrator
*****
Offline

Dipl. Paranoiac ®

Posts: 1162
Germany
Gender: male
Re: readdir: file order
Reply #6 - 02/17/05 at 18:04:26
 
Wotan   wrote on 02/17/05 at 17:07:52:
Sorry, I am still not sure. Here is the PHP doc for readdir (I just don't have a perl doc).

Code:
Description
string readdir ( resource dir_handle)

Returns the filename of the next file from the directory. The filenames are returned in the order in which they are stored by the filesystem.




Yes - but . and .. are the first files that have been created, haven't they.

Wotan   wrote on 02/17/05 at 17:07:52:
I.e. if a filesystem has the files unsorted, this is matter of the filesystem. You CAN'T relay on any order of the files actually.


No - as long as the files are returned in the order in which they are stored, so long . and .. are located on the first places.

But I think I can help to resolve this.
The code of 'sub read_dir' has to be changed in some parts.
It's not an act but currently I'm missing the time to do it.
Maybe next week ...
Back to top
 
 

Multimedia file viewing and clickable links are available for registered members only!!  You need to Login or Register!!


Greetings from Germany
Dieter Werner




Advertising
View Profile | WWW   IP Logged
Dieter Werner
Administrator
*****
Offline

Dipl. Paranoiac ®

Posts: 1162
Germany
Gender: male
Re: readdir: file order
Reply #7 - 02/18/05 at 10:52:07
 
This should do the job ...
search eAuction.pl for
Quote:
sub read_dir_range

search sub read_dir_range for the line
Code:
readdir THEDIR for 0 .. $trash; 


and replace it with this line
Code:
$trash > 1 && do { readdir THEDIR for 0 .. $trash }; 

Back to top
 
 

Multimedia file viewing and clickable links are available for registered members only!!  You need to Login or Register!!


Greetings from Germany
Dieter Werner




Advertising
View Profile | WWW   IP Logged
Pages: 1 2 3 


If you like eAuction, please Rate it.
If you don't like eAuction, please Rate it too.


1 is being poor and 10 is being excellent


EveryScript

ip-location


AccessControl - Members Only