Extend Year range selector
Want to choose a year before 1999?
Question:
How can I extend the year range in the DMXzone Calendar year selector?
Answer:
The default year range in the DMXzone Calendar is set to +/- 10 years from the current.
In order to extend this you need to place the following line of code in the Calendar's <script> tag included in the <body> tag of your page. Change the values to get the range needed:
yearRange: '-50:+10',
Your code should look somewhat like this:
<script type="text/javascript">
// <![CDATA[
$(function() {$('#dmxCalendar_1').datepicker({
skin : "dmxCalendar",
dateFormat : "M d, yy",
yearRange: '-50:+10',
showStatus : true,
numberOfMonths : [1,1],
showAnim : "slide",
showOptions :
{
direction : "up",
easing : "easeOutBounce"
},
duration : "slow",
showOn : "both",
buttonImage : "Styles/dmxCalendar/calendar_icon.gif",
buttonImageOnly : true
});})
// ]]>
</script>
Comments
Be the first to write a comment
You must me logged in to write a comment.