/* 
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
$(function() {
    var flaga1, flaga2, flaga3 , flaga4, flaga5 , flaga6;
   
    
    $('#form input').keyup(function(){
         if($('#form input[name=wt]').val().toLowerCase() === 'wtorek') {
             flaga1 = 'ok';
         }else{
             flaga1 = 0;
         }
         if($('#form input[name=sr]').val().toLowerCase() === 'środa') {
            flaga2 = 'ok';
         }else{
            flaga2 = 0;
         }
         if($('#form input[name=czw]').val().toLowerCase() === 'czwartek') {
             flaga3 = 'ok';
         }else{
             flaga3 = 0;
         }
         if($('#form input[name=pt]').val().toLowerCase() === 'piątek') {
             flaga4 = 'ok';
         }else{
             flaga4 = 0;
         }
         if($('#form input[name=sob]').val().toLowerCase() === 'sobota') {
             flaga5 = 'ok';
         }else{
             flaga5 = 0;
         }
         if($('#form input[name=nie]').val().toLowerCase() === 'niedziela') {
             flaga6 = 'ok';
         }else{
             flaga6 = 0;
         }
         if(flaga1==='ok' && flaga2==='ok' && flaga3==='ok' && flaga4==='ok' && flaga5==='ok' && flaga6==='ok' ){
             alert("BRAWO");
         }
    });
});

