buradaki konuda yazmıştım herhangi bir cevap gelmedi anlatacaklarım 1.1.1 versiyonu içindir diğer versiyonlardaki farklılıkları bilmiyorum ama çok fazla bir fark olduğunu sanmıyorum öncelikle temamızın file.html dosyasını açıyoruz
<form action="<?php echo $siteurl; ?>/file.php?f=<?php echo $fileId; ?>&action=addcomment" method="post" name="form" onsubmit="return verify()"> <textarea name="message" rows="5" cols="50"></textarea><br> <input type="submit" name="submit" value="Yorum Ekle"> </form>kısmını bulup aşağıdaki kodla değiştiriyoruz
<form action="<?php echo $siteurl; ?>/file.php?f=<?php echo $fileId; ?>&action=addcomment" method="post" name="form" onsubmit="return verify()">
<textarea name="message" rows="5" cols="50"></textarea><br>
<img id="resim" src="<?php echo $siteurl; ?>/captcha.php" />
<a href="#" onclick="document.getElementById('resim').src = '<?php echo $siteurl; ?>/captcha.php?'+Math.random();">Resmi Yenile</a>
<br />
<label for="security_code">Güvenlik Kodu: </label><input name="captcha_code" type="text" /><br />
<input type="submit" name="submit" value="Yorum Ekle">
</form>daha sonra ana dizinde yer alan file.php dosyasını açıp $fileComment = $_POST[message];satırının hemen altına
$captcha_code= $_POST['captcha_code'];
if(isset($_POST['captcha_code']) && isset($_SESSION['captcha_code'])) {
if(md5($_POST['captcha_code']) == $_SESSION['captcha_code']) {satırlarını ekliyoruz }
header ("Location: ".$_SERVER['HTTP_REFERER']);
} elseif ($action == 'tellfriend') {kodunun hemen üstüne iki tane } koyuyoruz if le açtığımız karşılaştırmayı kapatıyoruz.Son olarakda ekteki dosyayı indirip ana dizine koyuyoruz
herkeze iyi çalışmalar kolay gelsin.
