« Return to Thread: submit_to_remote with image

Re: submit_to_remote with image

by JannaB :: Rate this Message:

Reply to Author | View in Thread


Fred,

I thnk you may be wrong on this (for once!) -or-, more likely, I cant
find the right hash key for the image (I'm unable to discern the
correct syntax).
For example, the following works, but, my problem is that it doesn't
pick up the values of other controls on the form:

<%= link_to_remote image_tag("/images/icecube.gif"), {:url =>{:action
=> 'freezer'}} %>

when I follow what (I think) you have suggested:

<%= submit_to_remote 'Freezer', 'freezer', {:url => { :action =>
'freezer' }, :name => image_tag("/images/icecube.gif")} %>

doesn;t pick up the image. But The hash key may be something other
than 'name' (I have tried, 'image,' and 'img' but I dont see how this
would map to the name parameter in link_to_remote) -Janna B
--~--~---------~--~----~------------~-------~--~----~
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@...
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

 « Return to Thread: submit_to_remote with image