$('#dp1').datepicker({
    format: 'dd-mm-yyyy',
    endDate: Date.today()
});
            Asked
            
        
        
            Active
            
        
            Viewed 1,237 times
        
    0
            
            
         
    
    
        amphetamachine
        
- 27,620
- 12
- 60
- 72
 
    
    
        Chetana Jain
        
- 11
- 1
2 Answers
0
            
            
        Maybe you can use numberOfMonths
or you can read http://jqueryui.com/datepicker/#date-range
 
    
    
        manowar_manowar
        
- 1,215
- 2
- 16
- 32
- 
                    It s bootstrap datepicker in which use endDate to disable future dates but it is not working – Chetana Jain Dec 18 '14 at 13:48
- 
                    http://stackoverflow.com/questions/11933173/how-to-restrict-the-selectable-date-ranges-in-bootstrap-datepicker – manowar_manowar Dec 18 '14 at 13:59
0
            
            
        The Idea behind to disable future dates from current month is, to get current month dates and set it as end date.
$(function(){
var today = new Date();
var lastDate = new Date(today.getFullYear(), today.getMonth() + 1, 0); 
$('.datepicker').datepicker({format: 'mm/dd/yyyy',  startDate : new Date(), autoclose: true,endDate: lastDate});
})
 
    
    
        shobhit kumar
        
- 1
- 2