Permalink
Browse files

Merge pull request #1 from kidsil/patch-1

Adding changeable field name for the hidden input
  • Loading branch information...
2 parents 68cf826 + cf27977 commit 0d9b770f1ccf305664dd2c1852b47ce31b5673e6 @abecoffman committed Sep 15, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 bday-picker.js
View
3 bday-picker.js
@@ -30,6 +30,7 @@
"placeholder" : true,
"legend" : "",
"defaultDate" : false,
+ "fieldName" : "birthdate",
"hiddenDate" : true
};
@@ -71,7 +72,7 @@
// Create the hidden date markup
if(settings["hiddenDate"]) {
- $("<input type='hidden' name='birthdate' />").val(hiddenDate).appendTo($fieldset);
+ $("<input type='hidden' name='"+settings["fieldName"]+"' />").val(hiddenDate).appendTo($fieldset);
}
// Build the initial option sets

0 comments on commit 0d9b770

Please sign in to comment.