searching a specific file in a directory

P

Psapg

Hi!

I'm new to javasript, and i must confess to have borowed a few free scripts
from the net to satisfie my needs....

Still i can't find even an idea of ascipt to do this...
Please Help!!!

I have a webserver setup in my home, with an index file that is an access
comtrol page, that, if the authentication is sucessfull, takes the user to a
specific directory.
In this directory I only have image files in .jpg format.

I need to create a page were the user can either browse the entiry
directory, or specify a filename to search for, wildcards enabled, and
beiing able to see a reduced size image in the result page when hovering the
image/file result link.
Any Ideas?

Thnaks in advance, and sorry if my question seems too long or messy....

Paulo
 
R

RobG

Psapg said:
Hi!

I'm new to javasript, and i must confess to have borowed a few free scripts
from the net to satisfie my needs....

Still i can't find even an idea of ascipt to do this...
Please Help!!!

I have a webserver setup in my home, with an index file that is an access
comtrol page, that, if the authentication is sucessfull, takes the user to a
specific directory.
In this directory I only have image files in .jpg format.

I need to create a page were the user can either browse the entiry
directory, or specify a filename to search for, wildcards enabled, and
beiing able to see a reduced size image in the result page when hovering the
image/file result link.
Any Ideas?

Use normal file sharing? :)

The solution is best done server-side, which might be written in
JavaScript but probably would be better in some other language. A
script-based, client-side solution to generate image thumbnails would
be very inefficient; using it to generate document thumbnails is
probably impossible for all practical purposes. Having them generated
every time a visitor comes to the page would be plain wasteful and very
inelegant.

Some OS's allow you to specify actions when the contents of a directory
are changed, others allow a program to run a set intervals to check if
the contents have changed. A script could generate the thumbnails and
update the index page accordingly whenever a file is added or removed
(or shortly thereafter).

There are plenty of programs to generate image thumbnails, but
generating document thumbnails would remain a real challenge if various
file formats are to be supported.

The 'search and display' part could be done easily in JavaScript,
provided the listing and thumbnails are already available and the user
has some idea of how to use regular expressions.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,236
Members
46,825
Latest member
VernonQuy6

Latest Threads

Top