  | 
              
	              
	                
  
    
	 
        function noWeekends มันเรียกใช้งานใน text ยังงัยครับ ผมเลือกเหมือน datepicker ธรรมดามันไม่ขึ้น     | 
   
  
    |   | 
   
 
 
 
              
  
          
		
     
		
	  
        
             | 
            | 
            | 
             | 
         
        
             | 
                       | 
          
            
               
                 เปลี่ยนไปใช้ html 5 ดีกว่าครับ ไม่ต้องโหลด datepicker มาใช้ให้เสียเวลา 
 
<input type="date"  >                        
               
               | 
             
            
              
			                              
                              
              
                
                     | 
                     | 
                     | 
                 
                
                     | 
                  
                      
                        | Date :
                            2018-11-03 11:33:06 | 
                        By :
                            Chaidhanan | 
                         
                    | 
                     | 
                 
                
                     | 
                     | 
                     | 
                 
                | 
             
           
			         | 
             | 
         
        
             | 
            | 
             | 
             | 
         
          
	    
     
               
		
     
		
	  
        
             | 
            | 
            | 
             | 
         
        
             | 
                       | 
          
            
               
                 Code (JavaScript) 
<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title>Date picker no weekend.</title>
        <meta name="viewport" content="width=device-width, initial-scale=1">
		
		<link rel="stylesheet" href="https://code.jquery.com/ui/1.12.1/themes/smoothness/jquery-ui.css">
    </head>
    <body>
        <form method="get">
			<input id="mydatepicker">
		</form>
        <script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
		<script src="https://code.jquery.com/ui/1.12.1/jquery-ui.min.js"></script>
        <script>
			function noWeekends(date) {
				var day = date.getDay();
				if (day == 0 || day == 6) {
					return [false, '', 'Nope!!'];
				}
				return [true, '', ''];
			}
            $('#mydatepicker').datepicker({
				'beforeShowDay': noWeekends
			});
        </script>
    </body>
</html>
 
 
มันไม่ขึ้นยังไงครับ? ผมลองมันก็ใช้ได้ ตรงเสาร์ อาทิตย์ก็จะเลือกไม่ได้ตามเงื่อนไข แล้วจะให้มันเป็นยังไงครับ?                        
               
               | 
             
            
              
			                              
                              
              
                
                     | 
                     | 
                     | 
                 
                
                     | 
                  
                      
                        | Date :
                            2018-11-03 13:07:57 | 
                        By :
                            mr.v | 
                         
                    | 
                     | 
                 
                
                     | 
                     | 
                     | 
                 
                | 
             
           
			         | 
             | 
         
        
             | 
            | 
             | 
             | 
         
          
	    
     
               
		
     
		
	  
        
             | 
            | 
            | 
             | 
         
        
             | 
                       | 
          
            
               
                 ขอบคุณครับ                        
               
               | 
             
            
              
			                              
                              
              
                
                     | 
                     | 
                     | 
                 
                
                     | 
                  
                      
                        | Date :
                            2018-11-05 07:58:16 | 
                        By :
                            pannawitaim | 
                         
                    | 
                     | 
                 
                
                     | 
                     | 
                     | 
                 
                | 
             
           
			         | 
             | 
         
        
             | 
            | 
             | 
             | 
         
          
	    
     
      		  
	
     | 
   
 
                 |