tc kimlik no doğrulama
2
●1.976
- 26-01-2016, 13:57:57nüfus dairesinden verileri doğrulama gerekiyor sadece yapabilecek ücretiyle birlitke skype adersini pm atsın lütfen
- 26-01-2016, 16:04:59marzenbecher adlı üyeden alıntı: mesajı görüntüle
Nüfüs dairesinden nasıl yapılır bilmiyorum ama TC kimlik no'nun bi algoritması var. Php ile basit bir fonksiyon yazarak girilen TC 'nin doğru olup olmadığını kontrol edebilirsin.
Örnek Fonksiyon Kodlarına Şu Linkten Ulaşabilirsiniz.
https://www.r10.net/php/830203-php-il...onksiyonu.html
-- Edit:
birde ücretsiz apisi varmış,
https://tckimlik.nvi.gov.tr/Service/KPSPublic.asmx
Buradan SOAP ile sanırım kontrol ettirebilirsiniz. - 26-01-2016, 16:32:31Üyeliği durduruldu
<?php // Doğrulama Fonksiyonu function tcno_dogrula($bilgiler){ $gonder = '<?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <TCKimlikNoDogrula xmlns="http://tckimlik.nvi.gov.tr/WS"> <TCKimlikNo>'.$bilgiler["tcno"].'</TCKimlikNo> <Ad>'.$bilgiler["isim"].'</Ad> <Soyad>'.$bilgiler["soyisim"].'</Soyad> <DogumYili>'.$bilgiler["dogumyili"].'</DogumYili> </TCKimlikNoDogrula> </soap:Body> </soap:Envelope>'; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "https://tckimlik.nvi.gov.tr/Service/KPSPublic.asmx" ); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true ); curl_setopt($ch, CURLOPT_POST, true ); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); curl_setopt($ch, CURLOPT_HEADER, FALSE); curl_setopt($ch, CURLOPT_POSTFIELDS, $gonder); curl_setopt($ch, CURLOPT_HTTPHEADER, array( 'POST /Service/KPSPublic.asmx HTTP/1.1', 'Host: tckimlik.nvi.gov.tr', 'Content-Type: text/xml; charset=utf-8', 'SOAPAction: "http://tckimlik.nvi.gov.tr/WS/TCKimlikNoDogrula"', 'Content-Length: '.strlen($gonder) )); $gelen = curl_exec($ch); curl_close($ch); return strip_tags($gelen); } // İşlemi gönder ve sonuç $bilgiler = array( "isim" => "İSİM", "soyisim" => "SOYİSİM", "dogumyili" => "19xx", "tcno" => "xxxxxxxxxxx" ); // Sonucu göster $sonuc = tcno_dogrula($bilgiler); if($sonuc=="true"){ echo "Doğrulama başarılı"; }else{ echo "Doğrulama başarısız"; } ?>