This project is archived and is in readonly mode.

#1761 ✓wontfix
Colin Law

Add leading zeros capability to datetime_select and date_select

Reported by Colin Law | January 15th, 2009 @ 02:31 PM | in 2.x

Attached is a patch to add the option :leading_zeros_month_and_day to form helpers datetime_select and date_select. Obviously it adds leading zeros to the month and day fields to bring them up to fixed 2 digit width. The month is only affected if :use_month_numbers is also set. Patch also contains tests.

Comments and changes to this ticket

  • Pratik

    Pratik March 10th, 2009 @ 05:29 PM

    • Assigned user set to “Pratik”
    • State changed from “new” to “wontfix”
    • Title changed from “Patch to add leading zeros capability to datetime_select and date_select” to “Add leading zeros capability to datetime_select and date_select”

    I think this is not very frequently used to be in the core. I'd suggest putting up a plugin at github and we can reconsider it for inclusion in the core if many people use it.

    Thanks.

  • Ryan Bigg

    Ryan Bigg October 11th, 2010 @ 10:58 AM

    • Tag cleared.
    • Importance changed from “” to “Low”

    Automatic cleanup of spam.

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

Attachments

Pages