Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Jun 2nd, 2011  |  syntax: PHP  |  size: 0.46 KB  |  views: 262  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. $dtInicio = explode("/", $contrato['Contrato']['data_inicio']);
  2.                 $dtFim  = explode("/", $contrato['Contrato']['data_termino']);
  3.                 $dtEmissao = explode("/", $this->data['Recibo']['data_emissao']);
  4.                
  5.                
  6.                 $fim = mktime(0,0,0,$dtFim[1],$dtFim[0],$dtFim[2]);
  7.                 $inicio = mktime(0,0,0,$dtInicio[1],$dtInicio[0],$dtInicio[2]);
  8.                 $emissao = mktime(0,0,0,$dtEmissao[1],$dtEmissao[0],$dtEmissao[2]);
  9.                
  10.                 return ( ($inicio <= $emissao) && ($emissao <= $fim)) ? true : false;
clone this paste RAW Paste Data