I have this strange situation where I have a form and when you hit the form button an indicator is supposed to flash at the bottom of the screen and say something like ''Information Saved'' or ''Information not saved'', whatever. The problem is that instead of flashing the message when I submit the form I get a prompt box saying ''File Download'' and I am at a complete loss of why it is doing this. Here is my code: View- <% form_remote_tag :url => {:action => ''update_action'', :id => params[:id]}, :complete => "new Effect.Appear(''update_div''); new Effect.Pulsate(''update_div'');" do -%> <%= hidden_field(:user, :design) %> <%= submit_tag ''Update Template'' %> <% end -%>'' Controller- def update_action @account = params[:id] render :update do |page| page.replace_html ''update_div'', :inline => ''<b style = "color: red;">ARG</b>'' end end It is pretty straight forward, but like I said I''m at a loss of why the strange action. Any ideas? Thx, -S -- Posted via ruby-forum.com. --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@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 groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Do you mean a js alert? Blog: random8.zenunit.com Learn rails: sensei.zenunit.com On 05/02/2009, at 2:22 AM, Shandy Nantz <rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org > wrote:> > I have this strange situation where I have a form and when you hit the > form button an indicator is supposed to flash at the bottom of the > screen and say something like ''Information Saved'' or ''Information not > saved'', whatever. The problem is that instead of flashing the message > when I submit the form I get a prompt box saying ''File Download'' and I > am at a complete loss of why it is doing this. Here is my code: > > View- > <% form_remote_tag :url => {:action => ''update_action'', > :id => params[:id]}, :complete => "new Effect.Appear(''update_div''); > new Effect.Pulsate(''update_div'');" do -%> > > <%= hidden_field(:user, :design) %> > <%= submit_tag ''Update Template'' %> > > <% end -%>'' > > Controller- > def update_action > @account = params[:id] > > render :update do |page| > page.replace_html ''update_div'', > :inline => ''<b style = "color: red;">ARG</b>'' > end > end > > It is pretty straight forward, but like I said I''m at a loss of why > the > strange action. Any ideas? Thx, > > -S > -- > Posted via ruby-forum.com. > > >--~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@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 groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
i cant figure out how my syntax is wrong. Ive looked at various apis but they dotn give examples using paths but a book im using does for a simple case. Whats wrong with this <% form_remote_tag :url => multi_complete_project_tasks_path(@project), :method => :put, :html => multi_complete_project_tasks_path(@project), :method => :put do %> -- Posted via ruby-forum.com. --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@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 groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
can anyone help?: -- Posted via ruby-forum.com. --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@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 groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
do |form| --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@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 groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
hi vimal thanks but i dont think thats right. could you or someone show a call to form _remote_tag that will degrade if javascript is enabled in the browser? if youd like something to work on how about his from railscasts <% form_tag complete_tasks_path, :method => :put do %> <ul> <% for task in @incomplete_tasks %> <li> <%= check_box_tag "task_ids[]", task.id %> <%= task.name %> </li> <% end %> </ul> <%= submit_tag "Mark as Complete" %> <% end %> -- Posted via ruby-forum.com. --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@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 groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---