title: Warning: explode() expects parameter 2 to be string, Array given in (line 120 of display_ket.module
body: <p>can someone help me to resolve this problem I've try any solution but still getting error, for firts time I using split date then i use explode because i received error and using php 5.6 .. $par is input</p>
  
  <blockquote>
    <p>Warning: explode() expects parameter 2 to be string, array given in
    konversitgl()</p>
  </blockquote>
  
  <p>My Code . </p>
  
  <pre><code>function konversitgl($par){
   $elemen=explode("-",$par); // this line 120
   return $elemen[2].'/'.$elemen[1].'/'.$elemen[0];
   }
  function balikin_tgl($par){
  $elemen=explode("/",$par );
  return $elemen[2].'-'.$elemen[1].'-'.$elemen[0];
  }
  function tglInd($par){
    $elemen=explode("-",$par );
    $var=milih_bulan();
    return number_format($elemen[2]).' '.$var[$elemen[1]].' '.$elemen[0];
  }
  function tglformat($par){
    $elemen=explode("/",$par );
    return $elemen[2].'-'.$elemen[1].'-'.$elemen[0];
  }
  
  function get_triwulan($bln){
    if ($bln&lt;=3){
      $n = 1;
    } elseif ($bln&lt;=6){
      $n = 2;
    } elseif ($bln&lt;=9){
      $n = 3;
    } else { 
      $n = 4;
    }  
    return $n;
  }
  
  function valid_tanggal($tgl_cek){
    global $user;
    $panjang = strlen($tgl_cek);
    //if (!ereg ("([0-9]{1,2})/([0-9]{1,2})/([0-9]{4})", $tgl_cek)){
    if (!preg_match ("/([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})/", $tgl_cek)){
        $hasil_cek = false;
    }else{
        $tahun = substr($tgl_cek,-4);
        $tgl = substr($tgl_cek,0,2);
        $bulan   = substr($tgl_cek,3,2);
        if($bulan&gt;12){
           $hasil_cek = false;
        }else if($tgl&gt;31){
             $hasil_cek = false;
        }else{
          if($bulan==02){
             if($tgl&gt;29){
              $hasil_cek = false;
             }else{
              $hasil_cek = true;
             }
          }else{
             $hasil_cek = true;
          }
        }
    }
    return $hasil_cek;
  }
               db_set_active('default');
        $xx = date('Y-m-d');
        $yy = substr($xx,0,4);
        $mm = substr($xx,5,2);
        $dd = substr($xx,8,2);   
        if($awal==NULL){
          $awal  = $yy."-".$mm."-01";
        }
        if($akhir==NULL){
          $akhir  = $yy."-".$mm."-".$dd;
        }  
  </code></pre>