gs84
2011-Mar-11 15:22 UTC
Make client download and save files without showing file dialog box
Hi, How can i send data or file to client and force it to automatically download and save it in specified folder without showing file dialog box (Open / Save option) ? Thanks in advance for your help. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Colin Law
2011-Mar-11 15:28 UTC
Re: Make client download and save files without showing file dialog box
On 11 March 2011 15:22, gs84 <salimatag2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi, > > How can i send data or file to client and force it to automatically > download and save it in specified folder without showing file dialog > box (Open / Save option) ?I hope you can''t. It would be a serious browser security flaw if you could. Would you want a web page downloading and saving files onto your PC without your knowledge? Colin -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Walter Lee Davis
2011-Mar-11 15:32 UTC
Re: Make client download and save files without showing file dialog box
On Mar 11, 2011, at 10:22 AM, gs84 wrote:> Hi, > > How can i send data or file to client and force it to automatically > download and save it in specified folder without showing file dialog > box (Open / Save option) ? > > Thanks in advance for your help.Browsers don''t work that way, for very excellent reasons of security and not wanting to be hacked. Walter -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Michael Pavling
2011-Mar-11 15:35 UTC
Re: Make client download and save files without showing file dialog box
On 11 March 2011 15:22, gs84 <salimatag2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> How can i send data or file to client and force it to automatically > download and save it in specified folder without showing file dialog > box (Open / Save option) ?By writing a web browser that breaks all standards and conventions, then tricking loads of people into installing it... c''mon... internet 101... -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
gs84
2011-Mar-14 10:59 UTC
Re: Make client download and save files without showing file dialog box
Thanks to all for your answer. Can you suggest me another process to face this problem? Thanks. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Frederick Cheung
2011-Mar-14 11:48 UTC
Re: Make client download and save files without showing file dialog box
On Mar 14, 10:59 am, gs84 <salimat...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Thanks to all for your answer. > Can you suggest me another process to face this problem? >What''s the wider problem you''re trying to solve? Fred -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
gs84
2011-Mar-14 16:00 UTC
Re: Make client download and save files without showing file dialog box
On 14 mar, 12:48, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> On Mar 14, 10:59 am, gs84 <salimat...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Thanks to all for your answer. > > Can you suggest me another process to face this problem? > > What''s the wider problem you''re trying to solve? > > FredI want to send file/data to user without showing the file dialog box. Thanks. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Peter Hickman
2011-Mar-14 16:51 UTC
Re: Re: Make client download and save files without showing file dialog box
On 14 March 2011 16:00, gs84 <salimatag2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> On 14 mar, 12:48, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> What''s the wider problem you''re trying to solve? >> >> Fred > > I want to send file/data to user without showing the file dialog box.So what you are saying is that you want to use a web page to install malware on a users computer? Why would you want to do this and why do you think anyone here is going to help you? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Walter Lee Davis
2011-Mar-14 16:53 UTC
Re: Re: Make client download and save files without showing file dialog box
On Mar 14, 2011, at 12:00 PM, gs84 wrote:> > > On 14 mar, 12:48, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> On Mar 14, 10:59 am, gs84 <salimat...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Thanks to >> all for your answer. >>> Can you suggest me another process to face this problem? >> >> What''s the wider problem you''re trying to solve? >> >> Fred > > > I want to send file/data to user without showing the file dialog box. > > Thanks.Is this file data something which the user''s browser understands how to process and display? If so, you could try just linking to it. Don''t try to tell the browser what to do with it, just leave it up to the browser. If the browser understands it and can display it, then it will. If it doesn''t, then it will prompt for a save or a hand-off to a helper application. This is basic browser behavior as codified in Mosaic in the mid-90s, and hasn''t changed at all since then. The list of things browsers understand natively HAS gotten longer since then, but the premise -- that it''s up to the browser what to do with whatever you link to -- is the same. Walter> > -- > You received this message because you are subscribed to the Google > Groups "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails- > talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org > . > For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en > . >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Frederick Cheung
2011-Mar-14 17:56 UTC
Re: Re: Make client download and save files without showing file dialog box
On 14 Mar 2011, at 16:00, gs84 <salimatag2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > > On 14 mar, 12:48, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> On Mar 14, 10:59 am, gs84 <salimat...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Thanks to all for your answer. >>> Can you suggest me another process to face this problem? >> >> What''s the wider problem you''re trying to solve? >> >> Fred > > > I want to send file/data to user without showing the file dialog box. >What I meant was what are you trying to do that means you have this need? Fred> Thanks. > > -- > You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en. >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
gs84
2011-Mar-15 10:00 UTC
Re: Make client download and save files without showing file dialog box
> > > On 14 mar, 12:48, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > >> On Mar 14, 10:59 am, gs84 <salimat...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Thanks to all for your answer. > >>> Can you suggest me another process to face this problem? > > >> What''s the wider problem you''re trying to solve? > > >> Fred > > > I want to send file/data to user without showing the file dialog box. > > What I meant was what are you trying to do that means you have this need? > > Fred >In my application, while user''s registration i am creating a file which users have to save, because that file will be use for their authentication. And may be for elderly people, showing dialog box and ask them to choose path for saving that file could ne complicated for them. That''s why i want to save that file in specified path without showing the file dialog box. Thanks. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Michael Pavling
2011-Mar-15 10:25 UTC
Re: Re: Make client download and save files without showing file dialog box
On 15 March 2011 10:00, gs84 <salimatag2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:>> What''s the wider problem you''re trying to solve? > > And may be for elderly people, showing dialog box and ask them to > choose path for saving that file could ne complicated for them. > That''s why i want to save that file in specified path without showing > the file dialog box.That''s a very nice intention; to be worrying about the needs of the users, but you should be able to see that if such a process was possible, those self same easily confused elderly people would quickly become targets of malicious downloads. If nice people can download files quietly in the background, without the user knowing, then so can nasty people.> In my application, while user''s registration i am creating a file > which users have to save, because that file will be use for their > authentication.Can you not store what you need in a cookie? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
gs84
2011-Mar-15 12:08 UTC
Re: Make client download and save files without showing file dialog box
> > Can you not store what you need in a cookie?No. I can''t because user has to use it for every authentication. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Michael Pavling
2011-Mar-15 12:14 UTC
Re: Re: Make client download and save files without showing file dialog box
On 15 March 2011 12:08, gs84 <salimatag2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:>> Can you not store what you need in a cookie? > > No. I can''t because user has to use it for every authentication.What is the user supposed to do with it? They won''t even know it''s there in your design. So what if someone who can get hold of that file, can they masquerade as the user? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
gs84
2011-Mar-21 15:42 UTC
Re: Make client download and save files without showing file dialog box
So as this is not possible, is there a way to change (message, ...) the file dialog box in Rails? Thanks -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Peter De Berdt
2011-Mar-21 16:30 UTC
Re: Re: Make client download and save files without showing file dialog box
On 21 Mar 2011, at 16:42, gs84 wrote:> So as this is not possible, is there a way to change (message, ...) > the file dialog box in Rails?It''s a browser thing, so no. Rails, PHP, Java, the Pope, none of them can change something that''s just part of how the browser itself was programmed. Best regards Peter De Berdt -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Peter
2011-Mar-22 14:36 UTC
Re: Make client download and save files without showing file dialog box
On Mar 21, 11:30 am, Peter De Berdt <peter.de.be...-LPO8gxj9N8aZIoH1IeqzKA@public.gmane.org> wrote:> It''s a browser thing, so no. Rails, PHP, Java, the Pope, none of them > can change something that''s just part of how the browser itself was > programmed.Related question that I''m interested in but might also help the OP: Is there a way to control what type of files the dialog box is looking for and/or where they start looking? I can''t seem to remember if I''ve seen any sites do this, but its common if the file you want them to find has a certain extension or type that will help narrow it down. Thanks, \Peter -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Colin Law
2011-Mar-22 16:00 UTC
Re: Re: Make client download and save files without showing file dialog box
On 22 March 2011 14:36, Peter <ppgengler-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> On Mar 21, 11:30 am, Peter De Berdt <peter.de.be...-LPO8gxj9N8aZIoH1IeqzKA@public.gmane.org> wrote: >> It''s a browser thing, so no. Rails, PHP, Java, the Pope, none of them >> can change something that''s just part of how the browser itself was >> programmed. > > Related question that I''m interested in but might also help the OP: Is > there a way to control what type of files the dialog box is looking > for and/or where they start looking? I can''t seem to remember if I''ve > seen any sites do this, but its common if the file you want them to > find has a certain extension or type that will help narrow it down.We are talking about *downloading* files here, so the browser dialog box is not looking for a type of file at all, just asking whether and where to save the downloaded file. It is up to the browser and its configuration which directory to start at. Colin -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.