File: /home2/yenicep/public_html/x-aktiflestir.php
<?
if($_REQUEST['hash']=='860e6a977d2b47712a6d17cebefc42cb' and $_REQUEST['policeno']!=''){
header('Content-Type: application/json; charset=utf-8');
include 'functions-development.php';
$hdi_policeNo=p('policeno');
$s = "select * from kaskolu_cihazlar where hdi_policeNo='$hdi_policeNo'";
$q = $func->query($s);
$rs= $q->fetch();
if($rs->id){
if($rs->policeno_onay==0){
if($rs->policeno_aktiflik==0){
if($rs->Result=='Success'){
$tarih=gunceltarihsaat();
$func->query("update kaskolu_cihazlar set policeno_aktiflik='1' , policeno_aktiflik_tarih='$tarih' where id='$rs->id'");
$return->message="Police aktif edildi";
}else{
$return->message="Ödeme Başarisiz oldugu için police no aktiflik olusturulmadı";
}
}else{
$return->message="Poliçe zaten aktif";
}}else{
$return->message="Poliçe onayı geçersiz";
}
}else{
$return->message="Police Bulunamadı";
}
echo json_encode($return);
}
?>