Skip to content

Instantly share code, notes, and snippets.

@ksnider
Last active December 11, 2015 08:58
Show Gist options
  • Select an option

  • Save ksnider/4576511 to your computer and use it in GitHub Desktop.

Select an option

Save ksnider/4576511 to your computer and use it in GitHub Desktop.
The code to put in an html snippet in an InfusionSoft web form to add a jQuery UI datepicker to a date field, in this case, inf_custom_Date.
<style>
#inf_custom_Date {
width:160px !important;
float:left !important;
display:inline !important;
}
#inf_custom_ApptHour {
width:100px;
float:right;
display:inline;
position: relative;
top: -27px;
left: -112px;
}
</style>
<link rel="stylesheet" type="text/css" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.6/themes/base/jquery-ui.css" media="all" />
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.9/jquery-ui.min.js"></script>
<script>
jQuery(function() {
jQuery('#inf_custom_Date').datepicker({
changeMonth: true,
changeYear: true,
minDate: 0,
maxDate: +20,
showOtherMonths: true,
selectOtherMonths: true
});
});
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment