Looking for a fast directory listing

 
Post new topic   Reply to topic    Aprelium Forum Index -> General Questions
View previous topic :: View next topic  
Author Message
jrdeahl
-


Joined: 27 Dec 2006
Posts: 50

PostPosted: Fri May 23, 2008 11:22 am    Post subject: Looking for a fast directory listing Reply with quote

Using x2 on a p4 machine.

Need a faster directory listing over the default. The default takes 75 seconds to list 3,790 files.

Last year I heard rumors abyss was going to speed it up because apache is a lot faster (5 seconds). Any more on this?

Need something to speed it up!



John


Last edited by jrdeahl on Thu May 29, 2008 10:32 pm; edited 3 times in total
Back to top View user's profile Send private message
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Tue May 27, 2008 3:29 pm    Post subject: Re: Looking for a fast directory listing Reply with quote

jrdeahl,

Writing your own PHP (or any language) directory listing script will certainly be faster. The default directory listing of Abyss Web Server uses the SSI engine (which is not fast) and sends data in small chunks. This will be fixed in 2.6.
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
jrdeahl
-


Joined: 27 Dec 2006
Posts: 50

PostPosted: Thu May 29, 2008 10:30 pm    Post subject: Reply with quote

After looking and testing several php scripts I think I have found the fastest one.

This script displays what ever you want for a picture, some text and then the files. Displaying almost 4,000 files is done by starting right away displaying to the screen and then completeing in about 20 seconds.

Alter to your desire. Does not show file sizes, etc.

/********************************************************************
* function that reads directory content and
* returns the result as links to every file in the directory
*
* toss it into any directory and get a list of links to every file
*
* This program is free software licensed under the
* GNU General Public License (GPL).
*
*********************************************************************/
function directory($result) {

$handle=opendir(".");
while ($file = readdir($handle)) {
if ($file == "." || $file == "..") { } else { print "<a href=$file>$file</a><br>"; }

}
closedir($handle);

return $result;
}


?>
<img src="http://www.yourwebsite.com/image.jpg"
<p>
<p>
<b>Complete directory list MAY TAKE AWHILE TO DISPLAY.</b>
<p>
<b>Use your browser Find/Search feature to search.</b>
<p>
<b>Right click mouse on file to save to your computer.</b>
<p>
<?
echo directory($result);
?>
Back to top View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> General Questions All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group