[Seaside] Choose Directory Window

alexandre bp abalonpe at ulb.ac.be
Sat Dec 4 21:37:50 UTC 2010


Ok I didn't know that.
So, in other words, here is the situation:

   - A user wants to export something from my website.
   - He clicks on the button 'export' that I created.
   - I have implemented that when this button is clicked, a file is created
   and a content is written in it, then the file is closed.
   - The web-browser is going to ask where the user wants to put the file or
   is going to put it in a default directory automatically?

Thank you for your answer :)
cheers
alex


2010/12/4 Lukas Renggli <renggli at gmail.com>

> The security model of HTTP/JavaScript does not allow such a thing.
> This is the web-browser that does the handling of the downloaded file
> automatically. Possibly there is a way to circumvent that with
> Flash/Java, but that's not advisable in my opinion.
>
> Lukas
>
> On 4 December 2010 13:54, alexandre bp <abalonpe at ulb.ac.be> wrote:
> > Thx but actually I'd like to choose the directory (not a file) so that
> the
> > user can download the file (which comes from my website) where he wants.
> > Alex
> >
> > 2010/12/4 Robert Sirois <watchlala at hotmail.com>
> >>
> >> WAFileUploadTag
> >>
> >> " I think you end up with a WAFile instance or something? I'd have to
> >> look, but you can always just explore it "
> >> html fileUpload
> >>     on: #iVar of: self.
> >>
> >> RS
> >>
> >> ________________________________
> >> From: abalonpe at ulb.ac.be
> >> Date: Sat, 4 Dec 2010 16:41:16 +0100
> >> Subject: [Seaside] Choose Directory Window
> >> To: seaside at lists.squeakfoundation.org
> >>
> >> Hi,
> >> I'd like to open a new window from my webpage to ask the user to choose
> a
> >> directory where he wants to save a file.
> >> I tried this:
> >> canvas submitButton
> >>
> >> callback:[
> >>
> >> fileWindow := FileDialogWindow new.
> >>
> >> directoryPath := fileWindow chooseDirectory:'Choose a directory'.];
> >>
> >> with:'Choose directory'.
> >>
> >> It works but the window is open in pharo and not on my website.
> >> How can I change that?
> >> Thx in advance.
> >> alex
> >> _______________________________________________ seaside mailing list
> >> seaside at lists.squeakfoundation.org
> >> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> >> _______________________________________________
> >> seaside mailing list
> >> seaside at lists.squeakfoundation.org
> >> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> >>
> >
> >
> > _______________________________________________
> > seaside mailing list
> > seaside at lists.squeakfoundation.org
> > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> >
> >
>
>
>
> --
> Lukas Renggli
> www.lukas-renggli.ch
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20101204/c75e7c17/attachment.htm


More information about the seaside mailing list