View Full Version : Javascript
flablam
06-26-2006, 04:05 PM
Hello everyone!
I have this problem that I have not been able to figure out. I'm not looking for all the code... just if someone could point me in the right direction.
What I'm trying to do is have a list box or dynamic menu that lists the folders and files of local directories. I was thinking that this could be done in javascript and while I've found some steps in the right direction I don't think it it exactly what I'm looking for. So if anyone has an idea or two or some words of wisdom I would be greatly appreciative.
Thank you very much,
flablam
DjVoyager
06-26-2006, 11:03 PM
Hey Flablam! Good to hear from you again.
About Javascript; I am not good at Javascripting but DHTML (http://www.dynamicdrive.com/) might have what you're looking for.
Good luck!
danlefeb
06-27-2006, 06:51 AM
Flabam, are you looking for something that needs to be on the public web or is it for internal network uses? Also, are you looking to view the end user's folder structure, or the server's?
It's impossible to actually view the end user's folder structure - for security purposes. However, if you're looking to view the server's folders you could get something like this:
http://www.http-com.com/
http://www.c-point.com/JavaScript/articles/file_access_with_JavaScript.htm
You could always write a little program like they did for FolderShare that uploads basically a database of your folder structure to the server. But I don't know if you're wanting to get that involved. :)
Hope that helps point you in the right direction!
flablam
06-27-2006, 09:38 AM
Thanks guys! Yeah I forgot to mention server vs. local. The purpose of this is local. I wrote a javascript (well pasted code and changed it to my needs... not too good at javascript :D) for a menu system here at my work where you select the type of product, then a list of companies comes up.. then when you select a company all the products come up. Now with this system I had to type in every single item and do lots of code so this is a big script. All these companies/products have corresponding files that we use so I am trying to get my html file to list the directory and when you select something it changes to that directory instead. I know, quite a big feat and javascript might not be the right path but if you have any more information for me then I would appreciate it very much! Thanks!
-flablam
laxman
06-27-2006, 09:54 AM
it might be easier to go to cmd and just type dir in the right folder. Then copy and paste the list of files into a notpad document. Then instead of looking for the folder structure, get a script that reads the names from the notepad file and inputs them. That is a pretty common thing to do so it should be in java books or even on the internet.
flablam
06-27-2006, 09:56 AM
Thanks laxman! I'll check that out!