473,230 Members | 1,539 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,230 software developers and data experts.

uploading directories recursively

Hi,

Is uploading recursively directories to a web server possible with
JavaScript?

I mean is it possible read a directory recursively and dynamically
construct <input type="file"> with value - the path to the
corresponding file and call submit with the script.

Thank you.

--
Kamen TOMOV
Feb 21 '06 #1
3 1884
Kamen TOMOV wrote:
Is uploading recursively directories to a web server possible
with JavaScript?
Not using javascript from a remote web sites under the standard security
restrictions (the browser does not normally expose the local files
system, or facilitate the loading of files from the local computer into
a variable).
I mean is it possible read a directory recursively and
dynamically construct <input type="file"> with value
- the path to the corresponding file and call submit
with the script.


In Windows IE, with security practically disabled, you can do exactly
that (You can instantiated a Scripting.FileSystemObject activeX object
and read the entire file system, including all the file names in all
directories). But with that level of security you can also re-format the
user's hard drives so you cannot expect these facilities over the public
Internet.

Richard.
Feb 21 '06 #2
On Tue, Feb 21 2006, Richard Cornford wrote:
Kamen TOMOV wrote:
Is uploading recursively directories to a web server possible
with JavaScript?


Not using javascript from a remote web sites under the standard security
restrictions (the browser does not normally expose the local files
system, or facilitate the loading of files from the local computer into
a variable).


Thanks. So does this mean that it is possible to be done if the
security of the browser is lowered? Can it be implemented for
different kind of browsers? Is it possible to lower the security only
for a particular remote web site?

Regards,
--
Kamen TOMOV
Feb 21 '06 #3
Kamen TOMOV wrote:
On Tue, Feb 21 2006, Richard Cornford wrote:
Kamen TOMOV wrote:
Is uploading recursively directories to a web server possible
with JavaScript? Not using javascript from a remote web sites under the standard security
restrictions (the browser does not normally expose the local files
system, or facilitate the loading of files from the local computer into
a variable).


Thanks. So does this mean that it is possible to be done if the
security of the browser is lowered?


Yes.
Can it be implemented for different kind of browsers?
Most certainly. XPCOM provides a host object for that, and you can use
the XUL IXMLHTTPRequest implementation, XMLHttpRequest, to submit the
files.

<http://xulplanet.com/references/xpcomref/>
<http://xulplanet.com/references/objref/>
Is it possible to lower the security only for a particular remote web
site?


It is. RTFM.
PointedEars
Feb 22 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Andrew M. | last post by:
Is it possible to upload entire directories from a form in such a way that a user can browse to the folder on their local machine and select it for uploading or synchronization? I am using php5.
1
by: Trinity | last post by:
Hi, I want to delete a particular file in all the sub-directories. I am using the SHFileOperation() API. But it is not deleting the files recursively. Any sample code is appreciated. TIA
13
by: Sky Sigal | last post by:
I have created an IHttpHandler that waits for uploads as attachments for a webmail interface, and saves it to a directory that is defined in config.xml. My question is the following: assuming...
1
by: rsine | last post by:
I need to know all the directories that exist within a given location. Is there a way to get such a listing? Any help is appreciated. *** Sent via Developersdex http://www.developersdex.com...
5
by: rbt | last post by:
What is the most efficient way to recursively remove files and directories? Currently, I'm using os.walk() to unlink any files present, then I call os.walk() again with the topdown=False option...
6
by: Dreamcatcher | last post by:
Hello, I'm trying to learn some C, reading my book, Beginning Linux Programming I came across the following program. The program is supposed to walk through directory's and print all its...
3
by: DataSmash | last post by:
Hi, I need to organize thousands of directories full of files. I want to move these directories into other subdirectories. For example, all the directories that start with 01, move to a directory...
9
by: bhumikas | last post by:
Hi all, I need a help in perl script.The basic idea is,it must have command line arguments for the user flexibility.the files are in the format as shown below. MainFolder Directory ...
3
by: misceverything | last post by:
I am writing a script that will backup specified folders from one hard drive to another (for example, backup source "C:\DATA", destination "D: \Backup"), and was thinking of using shutil. What I...
0
by: VivesProcSPL | last post by:
Obviously, one of the original purposes of SQL is to make data query processing easy. The language uses many English-like terms and syntax in an effort to make it easy to learn, particularly for...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
0
by: jianzs | last post by:
Introduction Cloud-native applications are conventionally identified as those designed and nurtured on cloud infrastructure. Such applications, rooted in cloud technologies, skillfully benefit from...
0
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
0
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
1
by: davi5007 | last post by:
Hi, Basically, I am trying to automate a field named TraceabilityNo into a web page from an access form. I've got the serial held in the variable strSearchString. How can I get this into the...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.