Multiple upload

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • François Granger

    Multiple upload

    On a user workstation there is a file linked to many other files. The user
    upload this file to my server. I can build a list of these files. But I
    don't know the path to these files on the workstation. PHP does not give
    this information. I am looking for a simple solution from the user point of
    view for him to send me all these files.

    Because I don't know the path to the file, I can ask the user to type the
    path in a dialog box.

    I don't have, from the server, a possibility to upload the files on the
    workstation. And I don't know how the pre-fill the <input type="file" />
    field of a form.

    Am I wrong ?

    Is there a simple solution that I missed ?

  • Alvaro G Vicario

    #2
    Re: Multiple upload

    *** François Granger wrote/escribió (Mon, 19 Apr 2004 15:26:41 +0200):[color=blue]
    > I don't know how the pre-fill the <input type="file" />
    > field of a form.[/color]

    You can't. It's an elementary security measure. Otherwise, any web site
    could get a copy of any file in your computer.

    --
    --
    -- Álvaro G. Vicario - Burgos, Spain
    --

    Comment

    • François Granger

      #3
      Re: Multiple upload

      Le 19/04/04 16:37, dans 1efrv48t4r1a7.1 bojfkclq6agz.dl g@40tude.net, « Alvaro
      G Vicario » <alvaro_QUITAR_ REMOVE@telecomp uteronline.com> a écrit :
      [color=blue]
      > *** François Granger wrote/escribió (Mon, 19 Apr 2004 15:26:41 +0200):[color=green]
      >> I don't know how the pre-fill the <input type="file" />
      >> field of a form.[/color]
      >
      > You can't. It's an elementary security measure. Otherwise, any web site
      > could get a copy of any file in your computer.[/color]

      I was pretty sure that it was not possible, but I needed a confirmation.

      And it is not possible to upload a full directory in one click ?

      Muchas gracias.

      Comment

      • Alvaro G Vicario

        #4
        Re: Multiple upload

        *** François Granger wrote/escribió (Mon, 19 Apr 2004 18:24:45 +0200):[color=blue]
        > And it is not possible to upload a full directory in one click ?[/color]

        Nope, all we have is that ugly file input box. Have you considered using a
        Java applet? Java can do things like that and maybe someone already wrote
        an applet to upload directories.


        --
        --
        -- Álvaro G. Vicario - Burgos, Spain
        --

        Comment

        • John Dunlop

          #5
          Re: Multiple upload

          Alvaro G Vicario wrote:
          [color=blue]
          > *** François Granger wrote/escribió (Mon, 19 Apr 2004 15:26:41 +0200):
          >[color=green]
          > > I don't know how the pre-fill the <input type="file" />
          > > field of a form.[/color]
          >
          > You can't.[/color]

          Well, you *can*: "User agents may use the value of the value attribute
          as the initial file name" (HTML4.01, sec. 17.4.1). Whether what
          happens next works is another matter, and indeed YMMV.
          [color=blue]
          > It's an elementary security measure.[/color]

          Yes, that's pretty much the browser developers' excuse for not
          implementing it. But, no, there's nothing inherently insecure about
          suggesting default file names. Some browsers implement it, some
          don't. It comes as no surprise that Internet Explorer doesn't.
          [color=blue]
          > Otherwise, any web site could get a copy of any file in your computer.[/color]

          RFC1867, sec. 8, says:

          | It is important that a user agent not send any file that the user
          | has not explicitly asked to be sent. Thus, HTML interpreting agents
          | are expected to confirm any default file names that might be
          | suggested with <INPUT TYPE=file VALUE="yyyy">.

          RFC1867, "Form-based File Upload in HTML",


          --
          Jock

          Comment

          • Alvaro G Vicario

            #6
            Re: Multiple upload

            *** John Dunlop wrote/escribió (Mon, 19 Apr 2004 20:15:45 +0100):[color=blue]
            > Thus, HTML interpreting agents are expected to confirm any
            > default file names that might be suggested with <INPUT TYPE=file VALUE="yyyy">.[/color]

            Well, that sound's okay. I guess that feature would be useful for
            intranets.

            --
            --
            -- Álvaro G. Vicario - Burgos, Spain
            --

            Comment

            • François Granger

              #7
              Re: Multiple upload

              Le 20/04/04 9:24, dans l0kqubj4ueyg$.1 vccvws82w8cz.dl g@40tude.net, « Alvaro
              G Vicario » <alvaro_QUITAR_ REMOVE@telecomp uteronline.com> a écrit :
              [color=blue]
              > *** John Dunlop wrote/escribió (Mon, 19 Apr 2004 20:15:45 +0100):[color=green]
              >> Thus, HTML interpreting agents are expected to confirm any
              >> default file names that might be suggested with <INPUT TYPE=file
              >> VALUE="yyyy">.[/color]
              >
              > Well, that sound's okay. I guess that feature would be useful for
              > intranets.[/color]

              Thanks a lot for your help. I tested this and none of my browser keep the
              content of value="".

              All this look logical.

              Comment

              • David Mackenzie

                #8
                Re: Multiple upload

                On Mon, 19 Apr 2004 18:24:45 +0200, François Granger
                <fgranger@aluss inan.org> wrote:
                [color=blue]
                >Le 19/04/04 16:37, dans 1efrv48t4r1a7.1 bojfkclq6agz.dl g@40tude.net, « Alvaro
                >G Vicario » <alvaro_QUITAR_ REMOVE@telecomp uteronline.com> a écrit :
                >[color=green]
                >> *** François Granger wrote/escribió (Mon, 19 Apr 2004 15:26:41 +0200):[color=darkred]
                >>> I don't know how the pre-fill the <input type="file" />
                >>> field of a form.[/color]
                >>
                >> You can't. It's an elementary security measure. Otherwise, any web site
                >> could get a copy of any file in your computer.[/color]
                >
                >I was pretty sure that it was not possible, but I needed a confirmation.
                >
                >And it is not possible to upload a full directory in one click ?[/color]

                An <input type='file'> should allow selection of multiple files,
                although IIRC Opera is the only browser that supports it.

                Could you have your user zip their files and unzip them server-side?

                --
                David ( @priz.co.uk )

                Comment

                • François Granger

                  #9
                  Re: Multiple upload

                  Le 20/04/04 13:12, dans 8o0a8090dcilinj 0qm70d4p79om068 6t3f@4ax.com, « David
                  Mackenzie » <me@privacy.net > a écrit :
                  [color=blue]
                  > An <input type='file'> should allow selection of multiple files,
                  > although IIRC Opera is the only browser that supports it.[/color]

                  In php there is a multiple upload a option, but one has to select each
                  file... :-([color=blue]
                  >
                  > Could you have your user zip their files and unzip them server-side?[/color]

                  I am targeting really low level multiplatform users ;-)

                  But with no other solution, I may end up implementing this.

                  Thanks to all.

                  Comment

                  Working...