📁 PHP Dosya Yöneticisi
/
/
home
/
demodesigncom
/
falscripti.demodesign.com.tr
/
chatapi
📝
reply_coffee.php
← Geri Dön
<?php include "config.php"; include "chatgpt.php"; $coffees = $conn->query("select * from kahve_fal where durum = 0 order by id desc limit 1"); $apiKey = $conn->query("select * from ayarlar where id = 1")->fetch_assoc()["api_key"]; if($coffees->num_rows > 0){ while($coffee = $coffees->fetch_assoc()){ $iid = $coffee["id"]; $time = strtotime($coffee["created_at"]); $now = strtotime(date("Y-m-d H:i:s")); if(($now-$time) > 5*2){ $user_info = explode(",",str_replace("İlişki:","",$coffee["kisisel_bilgiler"])); $timestamp = strtotime(str_replace("/","-",$user_info[4])); $day = date('d', $timestamp); $month = date('m',$timestamp); $gptapi = new gpt(); $reply = str_replace("[p]","\n",$gptapi->kahve( $apiKey, $user_info[0], $user_info[3], $user_info[2], $user_info[6], $user_info[5], "Fallabi", "Aşk", "Genel") ); echo $reply; if(strlen($reply) > 30){ //kullanıcı falını cevapla, bildirim gönder vb. ayarları yapılabilir $conn->query("update kahve_fal set yorum = '$reply', durum = 1 where id = $iid"); } } } }
💾 Kaydet
İptal
📝 Yeniden Adlandır
İptal
Kaydet
🔐 Dosya İzinleri (chmod)
İzin Değeri:
Hızlı Seçim:
777
755
644
600
777
= Herkes okur/yazar/çalıştırır
755
= Sahip tam, diğerleri okur/çalıştırır
644
= Sahip okur/yazar, diğerleri okur
600
= Sadece sahip okur/yazar
İptal
Uygula