<script type="text/javascript">

// Requires jQuery UI - Core Modules from below.

// Use: Re-name 'datepicker' to match the Builder element name.

// Notice this is a class definition, not an id.
// This is because we assign a class 
// attribute that's the same as your fields id.

$(function() {
	jQuery(".datepicker").datepicker({
		onClose: function() {
 			// validate code, etc.
    	}
	});
});
</script>