Handling input date

0

I have an input of type date , I would like to manipulate this input, because when it is executed in iOS (phonegap app) it becomes a combo , so when I run an onChange event, there would be some way to validate if there was change and which one stopped, instead of "listening" each change my value and perform my function for every exchange?

    
asked by anonymous 08.06.2016 / 20:43

1 answer

1

Ola can have a simpler form, but this can work. You can add and remove a class to know whether the user has played or not.

  function verificarFuncao(){

      $('#input').toggleClass('clicado');

      if(('#input').hasClass('clicado')){
             console.log('foi clicado');
      }      
  }
    
08.06.2016 / 21:39