Tüm sayfa kodunu iletir misiniz inceleyelim.
Ayrıca cache silmeyi unutmayın. varsa geçici olarak cache kapatın.
buyrun hocam
<?php
function is_renew_invoice($invoiceid){
$invoice_result = localAPI('GetInvoice', ['invoiceid'=>$invoiceid]);
if($invoice_result['items']['item'][0]['type']=='Hosting'){
$h = Illuminate\Database\Capsule\Manager::table('tblhosting')->where('id',$invoice_result['items']['item'][0]['relid'])->first();
if($h->regdate!=$invoice_result['date']){
return true;
}else{
return false;
}
}elseif(strpos(strtolower($invoice_result['items']['item'][0]['type']),'domain' ) !== false){
$h = Illuminate\Database\Capsule\Manager::table('tbldomains')
->where('id',$invoice_result['items']['item'][0]['relid'])
->first();
if($h->registrationdate!=$invoice_result['date']){
return true;
}else{
return false;
}
}
}
add_hook('ClientAreaPage', 1, function ($vars) {
$total_raw = preg_replace("/[^0-9\.]/", '', $vars['invoice']['total']);
$subtotal_raw = preg_replace("/[^0-9\.]/", '', $vars['invoice']['subtotal']);
$tax_raw = preg_replace("/[^0-9\.]/", '', $vars['invoice']['tax']);
$credit_raw = preg_replace("/[^0-9\.]/", '', $vars['clientsdetails']['credit']);
$total_tr = number_format(($total_raw), 2, ',', '.') . ' TL';
$subtotal_tr = number_format(($subtotal_raw), 2, ',', '.') . ' TL';
$tax_tr = number_format(($tax_raw), 2, ',', '.') . ' TL';
$credit_tr = number_format(($credit_raw), 2, ',', '.') . ' TL';
return [
'total_raw' => $total_raw,
'subtotal_raw' => $subtotal_raw,
'discount_raw' => $tax_raw,
'taxtotal_raw' => $credit_raw,
'total_tr' => $total_tr,
'subtotal_tr' => $subtotal_tr,
'tax_tr' => $tax_tr,
'tax_raw' => $tax_raw,
'credit_tr' => $credit_tr,
'usdc' => $c->currency
];
});