similar to: controller code for access to params in radio button column

Displaying 20 results from an estimated 10000 matches similar to: "controller code for access to params in radio button column"

2006 Mar 24
1
Radio Button Tag and hash @Params.
Hi, I''ve a little problem using the Radio Button Tag. I use the " @prove=MODEL.column_names() " to keep attribute names of a table. After i used this code to select a attribute subsets of them : <% i=''0''%> <% for @obj in @prove %> <% @key='':key''+i%> <%= radio_button_tag (@key,@obj) %> <%
2013 Jun 18
1
How to Pass Jquery selected dropdown values and radio button values to controller
Hi, I have an advance search page and its code is as follows - I have written my code like this <div class="container"> <%= form_tag search_index_path, method: :get do %> <%= radio_button_tag ''user_type'', ''customer'' %><p>Customer</p> <%= radio_button_tag ''user_type'',
2009 Feb 17
1
How to show div with radio button onclick
I am trying to get a div to show when a radio button is clicked but the problem is that the div is dynamically named. I am using the normal html for a radio button: <input type="radio" name="edit_option" checked="checked" value="this_appt"> Because observe field does not work well with radio buttons. I have tried adding an onclick with the div id:
2008 May 07
1
Change Focus of Radio Button
Hey ya''ll... Love learning Prototype so far... ran into a small problem today, from my google search it doesn''t seem like there is an easy way to do this... i hope i have assumed wrong! I need to change the focus of a radio button... I currently use this code to call focus to the first form element... i tried to reuse it to do radio buttons with no success
2006 Jun 28
3
observe_field and radio button... does not work?
I try to catch click event on radio button, but nothing is executed.... Tested with RoR 1.1.2 and 1.1.3. What am I doing wrong? <%= radio_button_tag(:city, ''Dublin'') %> <%= observe_field(:citi, :frequency => 0.5, :on => ''click'', :with => "''city='' +
2008 Jul 21
0
edit radio button values...
my problem is... during edit process radio button should be checked as default ..how can i do that ..pl help.. my edit .erb file <% form_tag (:action => ''update'', :id => @mobile )do%> <p><label for="book_title">Title</label>: <%= radio_button ''mobile'', ''brand'', ''yes'' :checked =>
2007 Aug 04
0
capturing radio button values for nested object
I have a user object and an account object. User has one account object. In the signup.rhtml I have a radio button that has three options for the membership (yearly, monthly and sample). How do I populate the account model when the user submits the form? Is the following syntax correct? <%= radio_button("user[account]", "membership", "Yearly") %>
2006 Mar 22
2
Radio Button Defailt Value?
I have: <%= radio_button ''foo'', ''bar_id'', ''1'' %> <%= radio_button ''foo'', ''bar_id'', ''2'' %> <%= radio_button ''foo'', ''bar_id'', ''3'' %> I would like to have option #3 be selected if foo.bar_id is nil. Is there a way to do
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 Mar 17
5
Radio Button Validation
I''m writing a quiz application and I need to validate the radio button reponses. I do not have the questions in a database, I just have forms which contain "question1" and then I strip out the "question" portion and just insert the number as the question''s id. So now I''m faced with the dilemma of making sure the radio buttons are pressed. Radio
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
2013 Mar 02
3
Help Radio button
Hi i''m fairly new to ruby on rails and i''m creating a form using simple_form and in one bit i have radio buttons and say i have 3 buttons a,b,c so i want it to be if a is pressed then certain text fields show, and if b is pressed a different set of text fields show and similarly for c. Can anyone help me on this? -- You received this message because you are subscribed to
2006 Jun 30
7
javascript woes with radio button groups
Ok! So I have this survey project I''m working on where there are a list of questions but only one shows up at a time. That part''s easy. And, it is fully functional as we speak (and I think even ''live'') however..... My boss wants to be able to have the survey go to the next question when a user selects an answer. This part is easy.. except..... IE
2007 Feb 03
7
Interesting radio button behavior with "onclick"
Hello: I have radio buttons like this: <% fields_for :goalhist do |g| %> <table> <tr> <td align=left><%= radio_button_tag (''duedate'', 0, checked = false, options = {:onclick => ""}) %> &nbsp;&nbsp;Start now </td> </tr> <tr id="detailed" style="display: none"><td colspan=2>
2005 Sep 20
1
radio buttons and event obvsering
Hi, I made a little utility class that turns on a particular div when a radio button is clicked - a RadioButtonDivToggler. As the name hopefully suggests, when a radio button from the same group is clicked, a different div is made visible and the others are hidden. In essence, it toggles on (makes visible) the div associated with the radio button from a group that you clicked. However,
2006 Aug 10
3
Radio buttons refusing to load checked...
Hi, Having big problems with radio buttons that just don''t make sense: <%= radio_button "events", "impact_type", true %> Positive <%= radio_button "events", "impact_type", false %> Negative This should create two radio buttons with the first one checked by default, right? Cos it doesn''t :( Any ideas would be great, Thanks,
2006 Feb 17
1
AJAX and radio buttons
Hi! How can i use ajax with radio buttons? I have form with 2 radio buttons, which updates div with the value of selected radio button. It worked correctly when i used submit button, but when i removed it and used observers it didn''t. When i press the first button it displays its value, but when i press the second button it displays new value for a moment (0.5s ?) and then suddenly
2009 Apr 15
0
Multiple CheckBox and Radio Buttons
I am using multiple check box (more than 1 checkboxes) and a radio button and when I click the "Submit" button, it calls the "create" method it is inserting only 1 value for checkbox and also for the radio button. Could you please tell how to insert multiple check box values in create. Also, in the scaffold edit page, the default "edit" method displays all
2006 Aug 01
3
Radio buttons and AJAX
Hi, Here is what I would like: 2 radio buttons: "yes" and "no" There will be 2 containers: <div id="yes" style="display: none;">Yes stuff</div> <div id="no" style="display: none;">No stuff</div> What I want is whenever the "yes" radio button is selected, on the "yes" div should be made
2006 Apr 27
0
radio buttons and $F function
Hello there, i working with prototype but i have a little doubt, I''ll always use the shortcut $F to get values in a form, that''s ok, but what happens if i need get the value of one of three radio buttons value? normally i get the radio button value with document.formName.radioName but the shortcuts on prototype works with the id, there is a prototype way to do this?? greets --