fu: Close-up of Fu, bringing a scoop of water to her mouth (Default)
fu ([personal profile] fu) wrote in [site community profile] changelog2011-09-22 04:44 am

[dw-free] add number of month to name of month on cc field

[commit: http://hg.dwscoalition.org/dw-free/rev/6ee1629925ee]

http://bugs.dwscoalition.org/show_bug.cgi?id=3927

Change months in dropdown when entering credit card from "January",
"February", etc to "January - 01", "February - 02", etc, as per discussion
in [site community profile] dw_accessibility

Patch by [personal profile] rb.

Files modified:
  • htdocs/shop/entercc.bml
--------------------------------------------------------------------------------
diff -r fec2678668be -r 6ee1629925ee htdocs/shop/entercc.bml
--- a/htdocs/shop/entercc.bml	Thu Sep 22 12:35:25 2011 +0800
+++ b/htdocs/shop/entercc.bml	Thu Sep 22 12:43:32 2011 +0800
@@ -102,7 +102,7 @@
             '--' => '',
             ccnum => LJ::html_text({ name => 'ccnum', id => 'ccnum', maxlength => 19 }) . $accepted_ccs,
             cvv2 => LJ::html_text({ name => 'cvv2', id => 'cvv2', maxlength => 4, size => 5 }),
-            expmon => LJ::html_select({ name => 'expmon', id => 'expmon', selected => $POST{expmon} }, map { $_ => LJ::Lang::month_long( $_ ) } 1..12 ),
+            expmon => LJ::html_select({ name => 'expmon', id => 'expmon', selected => $POST{expmon} }, map { $_ => LJ::Lang::month_long_ml( $_ ) . " - " . sprintf( '%0.2d', $_ ); } 1..12 ),
             expyear => LJ::html_select({ name => 'expyear', id => 'expyear', selected => $POST{expyear} }, map { $_ => $_ } 2011..2020 ),
         );
 
--------------------------------------------------------------------------------

Post a comment in response:

This account has disabled anonymous posting.
If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting

If you are unable to use this captcha for any reason, please contact us by email at support@dreamwidth.org