Displaying 20 results from an estimated 10000 matches similar to: "Re: RE: Re: Re: Auto refreshing a page based on select chang"
2006 Jan 06
12
Auto refreshing a page based on select change
Hi all,
I have a select helper form on a web page which contains a list of dates. When
the user selects a date, one of the other forms on the page needs to be updated
based on the newly selected date.
Is there a way to catch this event in Rails? Are we talking Ajax here? Or is
there a simpler way?
Thanks,
Dan
2006 Jun 06
0
Get value from form using rjs, and problem with Safari
Hi,
I have got two forms, the first is a textarea plus a link that activates
some javascript to change the form, the second activates some javascript on
the onchange event which changes it into a textarea form.
This works in Firefox, but not in Safari.
Also, I need the value which is selected. I''ve found an example that gives
the parameter to the javascript, like this:
<input
2006 Jul 02
6
remote form w/ evalScripts:true
Hello. I want to select an item from a select list and have that
result in an ajax call that updates two sections on the page. Here is
the code in the controller
def create
...
render :update do |page|
page.replace_html ''list_items'', :partial => ''lists/list_items''
page.replace_html ''add_item'', :partial =>
2006 Jun 14
4
Select box onchange problem
Hi,
i''ve got the following problem. I have a check_box witch shows
a list of varieties. Now i want to call a action when the user
changes his selection. (the method to be called, will store the
selection from the user).
This is my code:
<%= select(''variety'', ''variety_id'',
Variety.find_all.collect {|c| [c.description, c.id]},
2006 Jun 06
1
Getting value of form using Ajax (and problems with Safari)
I have got two forms, the first is a textarea plus a link that activates
some javascript to change the form, the second activates some javascript
on the onchange event which changes it into a textarea form.
This works in Firefox, but not in Safari.
Also, I need the value which is selected. I''ve found an example that
gives the parameter to the javascript, like this:
<input
2006 Jul 20
0
Getting joined collections on a form
Greetings, I''m looking for suggestions on how to simplify getting customer
addresses on a form:
I''m jumping between controller and view several times; alternating between
rhtml and rjs, in order to display customers and their addresses on an
invoicing form. It''s very messy.
I have a one to many relationship between Customer and Addresses, each
customer has one or more
2006 Jul 21
0
Selecting customers and addresses in a form (was Getting joined collections on a form)
(Sorry if you have received this twice, I''m having trouble sending mail to
the rails list)
Greetings, I''m looking for suggestions on how to simplify getting customer
addresses on a form:
I''m jumping between controller and view several times; alternating between
rhtml and rjs, in order to display customers and their addresses on an
invoicing form. It''s very
2007 Jan 16
1
Can't pass parameters to Ziya controller using url_for
Hi All,
I''m stuck yet again. I have an action on a controller that produces a
Ziya graph, which I call using the gen_chart() helper. However, I can''t
seem to pass more than one parameter through to the action.
<%= gen_chart( "overview_graph",
url_for( :controller => ''graph'', :action => ''graph'', :graph_id =>
2006 Jul 11
0
Please please somebody RESCUE me Reg. form_remote_tag !
Hi frenz,
I need to update "div_main_data" on click of one submit button and I
need to update "div_member" on change of one select option. But couldn''t
find any solution at the moment.
If I use -> :onChange =>''this.form.onsubmit()''
this update the whole "div_main_data" as I couldn''t toggle the update
parameter
in
2006 Jul 11
1
form_remote_tag ISSUE !
Hi frenz,
I need to update "div_main_data" on click of one submit button and I
need to update "div_member" on change of one select option. But couldn''t
find any solution at the moment.
If I use -> :onChange =>''this.form.onsubmit()''
this update the whole "div_main_data" as I couldn''t toggle the update
parameter
in
2009 Sep 02
8
select_month helper
I''m trying to rewrite a fusebox-like application (Active4D plugin to
4D database) in RoR/postgres and I''m doing okay - but keep running
into things that stump me. It seems like it takes me hours to figure
out something that I could have written in pure code in minutes.
The select_month and select_day helper has been my latest waste of
time. All I''m trying to do is add
2009 Jan 28
1
How to give onchange for select_year rails helper....
<%=select_year(Date.today,:include_blank=>true, :start_year =>
Date.today.strftime("%Y").to_i, :end_year => 1999)%>
i am using rhis helper... now i want to give onchange here....
Please help me to solve this ....
thanks in advance
JK
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because
2008 Jun 26
2
Problem with date_select after Rails 2.1 upgrade
Folks,
I think I should start a new thread for this, because a similar one I
saw is a bit old and the resolution there doesn''t seem to apply to
what I''m running into now.
Anyway, my date_select calls are bombing on me with the exception:
----
ActionView::TemplateError (wrong number of arguments (3 for 2)) on
line #8 of entries/_dates_form.haml:
8: = date_select(
2006 Apr 27
4
select item based on previous select list selection?
So I have a select list with a list of items. When a user selects an
item, another select list should have its default selected item set to a
specific item (the default associated with the first select list).
This is in a form to create a new task. The first select list is a list
of parent tasks. When one selects the parent task, the clients select
list must default to the same client as its
2006 Jun 15
0
retrieving parameter or selected value using remote_function
Hi,
Can anyone let me know how to fetch selected option from the following
select box :
<%= select(:category_view,:name,@categories_choices, {:include_blank =>
false},
{:onChange =>remote_function(:update => "div_team_coverage", :url =>
{:action => :set_team_values} ,:with => "category="+ escape(value))} )
%>
<div
2006 Jun 19
0
For toggling update "divs" in form_remote_tag on condition!
Hi,
I have an issue in updating two divs base on the condition. Like if I
submit with the submit button it needs to update the div "div_main_data"
and on change of one select option it needs to update another div call
"div_top_data".
<%= form_remote_tag( :update => "div_main_data", :url => { :action =>
:change_top_view }) %>
<!-- here i want
2006 Mar 29
4
using onchange options in forms
Hello,
I''m trying to get a select field to update a view via the ''onchange''
option. I''ve seen examples of it here in the forum where people hardcode
the forms and use javascript to trigger the change (and nearly all have
complained that it''s a hack) and I''m wondering if anyone has a more
elegant solution using the embedded ruby methods?
2006 Jan 22
0
Escaping and Unescaping text in ERb
Instead of continuing the thread hijack, I''ve started a new one....
Douglas Livingstone wrote:
> 2006/1/22, Kevin Olbrich <kevin.olbrich@duke.edu>:
>>
>> You know, this has been bothering me a bit lately. If the point of
>> doing an html escape on the output is to prevent security problems,
>> wouldn''t it make sense for the default action on
2006 Feb 21
4
Select error
This code:
<p>
<label for="resource_type">Type</label><br/>
<%= select(:resource, :type, %w{ Web Data }, { :include_blank => true
}) %>
</p>
Produces this error:
TypeError in Resources#new
Showing app/views/resources/_form.rhtml where line #6 raised:
wrong argument type String (expected Module)
Extracted source (around line
2006 Feb 10
0
AJAX update for select list onchange?
Hi Rails Users,
I have a select list that I''d like to use to update a div onchange.
Right now I just have the div appear, but not update:
<%= select_tag( "profiles_select", option_tags = @profiles,
{ :onchange => "new Effect.Appear(''the_profile'',
{ duration: 0.5 } );"