Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $netahsilatAyarlari = get_option("woocommerce_netahsilat_settings");
- if (substr(getenv("HTTP_HOST"), 0, 4) == "www.") {$domainadi = substr(getenv("HTTP_HOST"), 4);}else{$domainadi = getenv("HTTP_HOST");}$lisanskodu = md5($domainadi."Voww_n_eTahh_banks");$lisanskodu = base64_encode($lisanskodu);$lisanskodu = sha1($lisanskodu);$lisanskodu = base64_encode($lisanskodu);$lisanskodu = strtoupper(sha1($lisanskodu));if( $lisanskodu != $netahsilatAyarlari["lisanskodu"] ) {
- $ErrorMessage = "Lisans kodu hatalı";
- $form = '<div class="woocommerce-NoticeGroup woocommerce-NoticeGroup-checkout">';
- $form .= '<ul class="woocommerce-error message-wrapper" role="alert">';
- $form .= '<li>';
- $form .= '<span class="message-icon icon-close"></span>';
- $form .= 'Hata: <strong>'.$ErrorMessage.'</strong>';
- $form .= '</li>';
- $form .= '</ul>';
- $form .= '</div>';
- echo $form;
- die();
- }
- function TutarFormat($tutar){
- return number_format($tutar,2,".","");
- }
- function TutarYazdir($tutar){
- return number_format($tutar,2);
- }
- $binNumber = $_POST['binNumber'];
- $binNumber = substr($binNumber,0,6);
- $orderid = $_POST['orderid'];
- $order = new WC_Order($orderid);
- $Tutar = $order->get_total();
- $birim = "TL";
- $client = new SoapClient($netahsilatAyarlari["ClientURL"]."/PWS/PaymentWebService.svc?singleWsdl");
- $AuthenticationInfo = new stdClass();
- $AuthenticationInfo->UserName = $netahsilatAyarlari["UserName"];
- $AuthenticationInfo->Password = $netahsilatAyarlari["Password"];
- //$result = $client->GetPaymentSetList(array("authInfo"=>$AuthenticationInfo))->GetPaymentSetListResult;
- $result = $client->GetPaymentSetListBinNumber(array("authInfo"=>$AuthenticationInfo,"binNumber"=>$binNumber))->GetPaymentSetListBinNumberResult;
- $result = json_decode(json_encode($result), true);
- // echo "<pre>";print_r($result);echo "</pre>";
- $ErrorCode = $result["ErrorCode"];
- $ErrorMessage = $result["ErrorMessage"];
- ...............................................................
- .......................................
- ................
Add Comment
Please, Sign In to add comment