justhrun

curl->mandiri2.test.php

Aug 25th, 2016
1,214
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.93 KB | None | 0 0
  1. #!/usr/local/bin/php
  2. <?php
  3.     date_default_timezone_set('Asia/Jakarta');
  4.  
  5. // userid & PIN mandiri
  6.     define('USERID','blablaba04');
  7.     define('PASSWD','012345');
  8.     define('ACCNUM','0123456789012');
  9.  
  10. // penetapan tanggal from-to mutasi
  11.     $from_date = date("Y-m-01");
  12.     $to_date = date("Y-m-d");
  13.  
  14. // load Class
  15.     include('mandiri.class.php');
  16.     $mandiri = new bankMandiri;
  17.     $mandiri->userid = USERID;
  18.     $mandiri->password = PASSWD;
  19.     $mandiri->rekening = ACCNUM;
  20.  
  21.     $soawal = 0;
  22.     $soakhir = 0;
  23.  
  24. // ################ START ACTION ################# \\
  25. echo "<pre>";
  26. if($mandiri->login()){
  27.     $result = $mandiri->mutasi($from_date,$to_date);
  28.     $mandiri->logout();
  29.  
  30.     $soawal = $result['soawal'];
  31.     $mutasi = $result['mutasi'];
  32.     $soakhir= $result['soakhir'];
  33.  
  34.     if(count($mutasi)) print_r($result);
  35.     else echo "Hasil Check Mutasi Zero/Error";
  36. } else {                // ERROR LOGIN
  37.     echo "Error Login Internet Banking / Wait 10mnt";
  38. }
  39. echo "</pre>";
  40. ?>
Advertisement
Add Comment
Please, Sign In to add comment