similar to: need to display only two days in date_select

Displaying 20 results from an estimated 100000 matches similar to: "need to display only two days in date_select"

2007 Jun 13
3
date_select css options
Just looked at the Date helper in the rails API and noticed that none of the functions there (i.e. date_select) allow me to specify html options (i.e. class) for the generated selects. I was wondering how do other group members css format date select dropdowns? Best, Gabor --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google
2006 Feb 02
0
date_select problem
Whenever a date_select field fails validation, The returned date_select that has the .fieldwiterrors css class is wrapping and obscuring the month and day dropdowns. So basically I can only see the Year dropdown. The others are visible in the html markup but seem to be totally obscured.???
2006 Sep 28
0
:order => [:day, :month, :year] with date_select
I still get the year month day display using this option.. (Rails 1.1.6) I thought a patch solved it.... not yet included in this version ? is also the option :discard => :day included or not ? (I need a date selection with only month and year) thanks fir your info kad -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this
2006 Jul 31
3
date_select for valid days only. No Feb 30
I am looking for some advice on how to make a date select display only valid days of the year. The standard date helper allows for you to choose 31 days for every month of the year. Since not all months have 31 days this can lead to invalid date entries for scheduling. I am thinking that an approach where I have a drop down for month and then use AJAX or normal client side javascript to
2009 Mar 13
2
date_select and HTML options?
I have the following code, but can''t seem to get the class attribute to show up in the generated select elements. I saw something about a bug/patch. However, as am still learning RoR I didn''t want to jump to conclusions. Anyone see anything wrong: <%= f.date_select :expiration_date, :order => [:month, :year], :discard_day => true, :class => "dtfld" %>
2007 Oct 13
5
default date for date_select
Hi, How can I set a default date for a date_select? I''m trying to do something along the lines of: <%= date_select("requirement", "target_date", :end_year => 2020, :discard_day => true, :include_blank => true, :order => [:month, :year], :default => {:month => 10, :year => 2012 }) %> but the default that comes up on the form is blank month
2007 Apr 12
3
Radrails and date in mysql problem
Hi, Im using radrails and mysql database, im using DATE in mysql for a date of birth column, When i use this in Radrails the date shows as dropdown lists, the days and month are fine but the year list only shows 2002-2012. Is there any way of extending the years? as its not suitable for date of birth. Any help appreciated -- Posted via http://www.ruby-forum.com/.
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 Sep 15
1
In datetime_select, :order does not work, but it works for date_select Why
Hi All In my project I am to take date of birth from user so I used datetime_select. It renders three selection boxes, year, month and day. But I want order as day, month and year. I added :order option for datetime_select, it renders normal selection boxes with order year, month and day. Why :order does not work with datetime_select? see my following code <%= datetime_select(:user2,
2006 Dec 10
2
set specific date with date_select
Hi All I seem to have a problem with date_select methods. I cannot set a default date. I tried the following: <%= date_select( "post", "written_on", :selected => Date.new(2005,3,31), :order => [:day, :month, :year] ) %> But still I get todays date :( Any suggestions what I do wrong here ? Thnx a lot LuCa -- Posted via http://www.ruby-forum.com/.
2007 Dec 26
2
Overriding or changing HTML generated by date_select?
Hi, I''m looking for a way to customize the HTML forms generated by date_select. I''m especially keen on replacing the year and possibly day input by a simple text field, since honestly, I find listboxes for years to be quite retarded (if I wanted client-side validation, there would be better ways to do that instead of having people try and find their year of birth in a list of
2006 Sep 12
1
How to use a text box instead a lis for year in date_select
Hi, I have a date_select in my application and is used to select birth date of authers. So it is quite long list of years in drop down list and seems not practical. I want to have month and date drop downs as it is and to use a text box to enter only the year. Is it possible with date_select? Thank you. Sameera -- Posted via http://www.ruby-forum.com/.
2007 Apr 14
1
how to add class to date_select helper
Hi, I have this helper and would like to add a html class to each of the select box''s it generates, however I have been unable to find a way? <%= f.date_select ''date_of_birth'', :order => [:day,:month,:year], :start_year => 1940, :end_year => Time.now.year, :include_blank => true %> Any suggestions? thanks john -- Posted via
2007 Jul 04
0
Multiple date_select
Hi, I tried to create 2 date fields with date_select in ruby. But the names assigned to the two date fields are the same(date[year], date[month] and date[day] for both) when I view the page source. Is there any way to assign a different name to the second date_select field? Or in what else way can we use two date fields in a form? Please help. Thanks -- Posted via
2007 Apr 16
0
Default Year selection for date_select?
Hi, is it posible to tell rails to select a specific year/month/day when using a date_select helper? as mentioned in at http://dev.rubyonrails.org/ticket/6124 things like :select_year => 1960 wont work. Where would be a good location to look for such things when the api doesnt show it? Pascal --~--~---------~--~----~------------~-------~--~----~ You received this message because you are
2007 Jul 30
0
Setting AR attribute from date_select values?
I have a date select: <%= form_fields.date_select :birthday_on, :order => [:month, :day, :year], :start_year => 1900 %> In my controller I want to set the individual attribute. How do I do this? user.birthday_on = params[:user][:birthday_on] How do I convert this to a date so it set properly? Thanks for your time! -- Posted via http://www.ruby-forum.com/.
2006 Nov 04
2
date_select parameter
Trying to add start year to date_select <%= date_select(:start_year => 1980)%> It''s throwing an exception "wrong number of arguments (1 for 0) Can''t I add a start_year, API shows this option ? TIA Stuart http://en.wikipedia.org/wiki/Dark_ambient --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the
2007 Jan 11
5
how to have default date for date_select
lo there all, i want to have a date_select heper default to the year 2006, but cant seem to find out how to pull it off. any takers ? -- Posted via http://www.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
2008 Jun 17
0
how to set tabindex in date_select
<%= date_select(''user'', ''birthdate'', { :start_year => 80.years.ago.year, :end_year => 12.years.ago.year } ) %> work in rails 1.2.2 date_select(object_name, method, options = {}) I try many times but also didn''t know how to set tabindex in date_select --~--~---------~--~----~------------~-------~--~----~ You received this message
2006 Aug 31
0
date_select error
Hi, when I try to use a date_select like this: <%= date_select(:contact, :event, :discard_year => true) %> I get the following error: 1 error(s) on assignment of multiparameter attributes Ticket #3811 (http://dev.rubyonrails.org/attachment/ticket/3811/date_helper_megapatch_against_1.1.2.0) Says it''s already corrected but I''m using rails 1.1.6 an still get the error.