Kumar Saurav wrote: > I have to show window as like you got on click of save(or by pressing of > ctrl+s), which exact function like the crtl+s press. > Please let me know if anyone having any idea regarding this. > It would be great help for me.
If your user can hit the Submit button of a form - maybe labeled "Save" - the controller's action can call send_file. This returns to the user as the "Save As Dialog", which is what you describe. If your form depends on Ajax, you can add a tiny 1px <iframe> into your form. The Save button has this iframe as a _target, and calls a similar action via form Submit - not Ajax. The action will render a file with send_file, and send it to the <iframe>, which will pop up the Save As dialog. That is how you can use Save As without interrupting a page that uses Ajax. --~--~---------~--~----~------------~-------~--~----~ 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@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---