similar to: bad move? - complex form with *many* observe_field's

Displaying 20 results from an estimated 6000 matches similar to: "bad move? - complex form with *many* observe_field's"

2007 Mar 07
4
Ajax and IE6 - is there some sort of "trick"?
Hi, I''ve got some Ajax stuff that shows more or less of a complex form based on a radio button selection. A "radio_handler" controller action is the action for a form handler. Some seemingly simple "replace_html" fires as a result of different radio buttons being chosen (which should then show more or less of the form). This all works just great on Mac Safari and
2008 Jul 09
4
Auto Postback in Ruby On Rails
in some other language have a concept e.i "auto postback" So, in Ruby on rails is there any such option e.i "auto postback" or same as "auto postback" basically what i want ot do is that i have 2 select box One for "Industry" and other for "Chemical" 1st we show all the industry in "Industry" select box. if we select any 1 industry
2009 Nov 30
6
rails 2.2.3 dirty.rb field_changed? method throwing arg error on creating an obj
I have a new model I''ve just built. It''s associated with another model via has_many. I''m trying to create one of these obj''s for the first time and I keep getting an Argument Error as follows: ArgumentError (wrong number of arguments (3 for 0)): C:/Ruby/lib/ruby/gems/1.8/gems/activerecord-2.2.3/lib/ active_record/dirty.rb:135:in `field_changed?''
2008 Jul 26
4
simple_format, (long) urls, and wrapping
I''m using simple_format to format and display posted content from users. This content sometimes has urls in it. The problem I''m having is that if the urls are long enough to wrap, they do, but the url gets split with a <br> tag. Then, if the user clicks on the link, only the first, non-wrapped part of the link gets posted to the browser... and that''s an invalid
2007 Jul 14
3
observe_field, does this generate HTML?
I don''t have Rails installed at the moment, I''d like to check myself, but it''s just a simple curiosity. observe_field fits into replacement tags <%= %>, which caught my attention because as far as I know it''s just javascript observing a field and should not stick anything into HTML. Is <%= merely used as an enabling method, or will there actually be
2008 May 30
4
How to deal with observe_field in partials?
Hiyas I''m having a little problem with a observe_field in a partial "bokings/room_list": <%= select_tag "room_#{room.id}_grownups", options_for_select([0, 1, 2], room.grownups.length) %> <%= observe_field "room_#{room.id}_grownups", :url => set_number_of_grownups_booking_room_url(:id => room.id), :with =>
2006 Aug 15
4
observe_form not serializing form
I want to use observe_form to automatically save notes in a text_area. This is the code I have: <form id=''notes_form''> <%= text_area :contact, :notes, :cols => 40, :rows => 10, :id =>''notes_text_area'' %> <%= observe_form(''notes_form'', :frequency => 1,
2008 May 16
3
radio button observe field only triggers once
Hi, If i add field observers to radio button fields they trigger once but then nothing after that. I have multiple fields in a form that i need to know if one of them changes and which spedific field. Below is an example of two foelds i tested and they trigger once with the alert but then nothing after that. I also tried individual observers for each field test_yes and test_no but with the same
2006 Apr 03
6
problems with Rails 1.1 observe_field :with serialized
I''d like to use observe_field to watch a field, and then when it changes send the entire form to the server. I had been using <%= observe_field ''entity_name_''+@account.id.to_s, :frequency => 0.5, :update => ''auto_complete_''+@account.id.to_s, :url => { :controller => ''committees'', :action=>
2009 Feb 26
8
beginners question
hi group, I am making a little rails app to experiment with rails. It consists of one model, item, that represents an item on a todo list. A todo item has a description, a state (finished or not) and a due date. After changing the scaffold screens a bit, I wanted to be able to have no due date. I tried to do this by making a radio button; if ''no date'' is selected, the date
2008 Jun 19
5
observe_field
I have been trying to pass a collection_select parameter and a text field parameter to observe_field so that it watches both the parameters simultaneously. but what i can see is , when i select some value from drop down and dont write anything in text field its giving correct results.parameters are also correct passed, but just after that if i write something in text field that value also get
2008 Oct 11
8
Observing few fields in a form - Best Practise?
Hi, im looking to build a page similar to a shopping cart page. When you change the ''price'' or ''quantity'' fields, the total is calculated and displayed. There are other fields in the form which have no relation to this action. So i guess observe_form is not required. Can someone tell me what the best practise is for this?
2006 Mar 22
2
observe_form without ajax?
This betrays my lack of javascript knowledge, but is it possible to watch a whole form for changes and activate some javascript when those changes occur without any remote request? That is, I want to do exactly what observe_form does, but without the ajax call actually happening. I realize I could use the form_tag :onchange parameter, but that seems to be incapable of doing things like
2006 Apr 12
22
Dynamic Select Box
Hi, I''m new to rails/ruby having come from PHP and am just starting to get my head round how easy it can be :) However, can anyone point me in the right direction for dynamicaly updating a select box based upon the choice of a previous select box, without a page refresh. Any and all help greatly appreciated. Thanks -- Posted via http://www.ruby-forum.com/.
2006 Jul 11
9
problems with observe_field
Hi all, I''m having problems with an observe_field, this is the view: <%= form_tag %> <div id="content"> <p>Customer: <select name="cliente_id" id="cliente_id"> <option value="">Select a customer</option> <%= options_for_select Cliente.find_all.collect {|c| [c.razon_social, c.id]} %>
2006 Feb 16
4
newbie question regarding basic AJAX form verification
Hi, I''m confused about how form verification with AJAX works. Let''s say I have a ''new.rhtml'' view that contains a form with two fields, and the form action is ''create''. Let''s assume that I also want to do some type of data validation on one of the two fields via AJAX before I submit the form. But since I''ve already
2006 Aug 10
7
Radio Button events
Hi, I have observers for a group of radio buttons, an observe_field for each radio button (I think its not possible to have one observe_field for a group of radio buttons). Now, the problem is that when I click on one radio button, all the observers get trigerred, so the method which the observe_field calls gets the wrong result. I just want that method to get the radio button that is
2009 Jul 29
6
Doubt in nil object with ajax
hi this is my htnl <html> <head> <%= javascript_include_tag :defaults %> </head> <body> <%= form_tag nil, { :id => ''search_form'' } %> <%= text_field ''recipe'', ''name'' %> <%= end_form_tag %> <div id="recipe"> </div> <%= observe_form :search_form, :frequency =>
2006 Aug 16
8
Multiple (AJAX) Observers on the Same Field and MSIE
I have been using multiple observers, i.e., observe_field(), on the same input field and relying on them to execute in the same order that they appear in the page. This has been working fine in FireFox, but it does not seem to work in MSIE; the requests come in and are processed in a different order. Now, I''ve always been a little hesitant about using this technique, but it always
2006 Mar 21
4
Can RoR''s AJAX helpers do this?
Hi, I want to type text into an input field then on enter, use AJAX to update the value of an input field elsewhere on the screen. ''observe_field'' allows me to watch a form field and dynamically update a DIV. Is there a variation or other method to allow me to update a field instead? -- Posted via http://www.ruby-forum.com/.