sayfa.php
<?php require_once('ayar.php'); ?>
<?php
session_start();
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
$theValue = (!get_magic_quotes_gpc()) ? addslashes($theValue) : $theValue;
switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? "'" . doubleval($theValue) . "'" : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
$editFormAction = $_SERVER['PHP_SELF'];
if (isset($_SERVER['QUERY_STRING'])) {
$editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
}
if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "yorumyaz")) {
if (md5($_POST['guvenlikkodu']) == $_SESSION['guvenlik']) {
$insertSQL = sprintf("INSERT INTO yorumlar (yazan, yorum, yaziid) VALUES (%s, %s, %s)",
GetSQLValueString($_POST['yazan'], "text"),
GetSQLValueString($_POST['yorum'], "text"),
GetSQLValueString($_POST['yaziid'], "int"));
mysql_select_db($database_geceninrengi, $portalv1);
$Result1 = mysql_query($insertSQL, $portalv1) or die("bos alan birakilamaz<br><a href=\"javascript:history.go(-1);\">Geri</a>");
$insertGoTo = "oku.php?id=".$_POST['yaziid']."&yorum=ok";
header(sprintf("Location: %s", $insertGoTo));
} else { ?>
<script>
window.location = "sayfa.php?id=<?php echo $_POST['yaziid']; ?>&yorum=hata";
</script>
<?php
}
} else {
$chars = array("1","1","2","2","3","3","4","4","5","5","6","6","7","7","8","8","9","9","1",
"1","1","2","2","3","3","4","4","5","5","6","6","7","7","8","8","9","9","1",
"1","1","2","2","3","3","4","4","5","5","6","6","2","3","4","5","6","7","8","9");
$textstr = '';
for ($i = 0, $length = 8; $i < $length; $i++) {
$textstr .= $chars[rand(0, count($chars) - 1)];
}
$hashtext = md5($textstr);
$_SESSION['guvenlik'] = $hashtext;
$textstre = substr($textstr,0,1)."S4cvW2".substr($textstr,1,3)."my6Y2z".substr($textstr,4,3)."H4tUh5".substr($textstr,7,1);
}
$currentPage = $_SERVER["PHP_SELF"];
mysql_select_db($database_geceninrengi, $portalv1);
$query_kategorilistesi = "SELECT * FROM kategoriler ORDER BY kategoriadi ASC";
$kategorilistesi = mysql_query($query_kategorilistesi, $portalv1) or die(mysql_error());
$row_kategorilistesi = mysql_fetch_assoc($kategorilistesi);
$totalRows_kategorilistesi = mysql_num_rows($kategorilistesi);
$colname_sonyazilar = "-1";
if (isset($_GET['id'])) {
$colname_sonyazilar = (get_magic_quotes_gpc()) ? $_GET['id'] : addslashes($_GET['id']);
}
mysql_select_db($database_geceninrengi, $portalv1);
$query_sonyazilar = sprintf("SELECT * FROM yazilar WHERE id = %s ORDER BY id DESC", $colname_sonyazilar);
$sonyazilar = mysql_query($query_sonyazilar, $portalv1) or die(mysql_error());
$row_sonyazilar = mysql_fetch_assoc($sonyazilar);
$totalRows_sonyazilar = mysql_num_rows($sonyazilar);
$hjg4789 = $row_sonyazilar['id'];
mysql_select_db($database_geceninrengi, $portalv1);
$query_yorumlar = sprintf("SELECT * FROM yorumlar WHERE yaziid = '%s' AND onay='1' ORDER BY id DESC LIMIT 5000", $hjg4789);
$yorumlar = mysql_query($query_yorumlar, $portalv1) or die(mysql_error());
$row_yorumlar = mysql_fetch_assoc($yorumlar);
$totalRows_yorumlar = mysql_num_rows($yorumlar);
$yaziokunma = sprintf("geceninrengi%s", $row_sonyazilar['id']);
if($_COOKIE[$yaziokunma] == '1'){
} else {
mysql_select_db($database_geceninrengi, $portalv1);
mysql_query("UPDATE yazilar SET okunma = okunma+1 WHERE id='$row_sonyazilar[id]'", $portalv1);
$cook = $_COOKIE[$yaziokunma] + 1;
setcookie("$yaziokunma", "$cook", time()+86400);
}
?>
<base href="http://www.kalpgulu.org">
<html>
<head>
<meta http-equiv="Content-Language" content="tr">
<title><?php echo $row_sonyazilar['yazigirisi']; ?> + 18 sicak resimler - videolar - cet - sohbet - chat - izle - indir</title>
<meta name="description" content="<?php echo $row_sonyazilar['yazigirisi']; ?> + 18 sicak resimler - videolar - cet - sohbet - chat - izle - indir">
<meta name="keywords" content="<?php echo $row_sonyazilar['yazigirisi']; ?> + 18 sicak resimler - videolar - cet - sohbet - chat - izle - indir">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-9">
<meta name="robots" content="index, follow" />
<META NAME="googlebot" CONTENT="index, follow">
<meta name="robots" content="all">
<META NAME="robots" CONTENT="index, follow">
<META NAME="REVISIT-AFTER" CONTENT="1 Days">
<link rel="stylesheet" type="text/css" media="screen" href="images/style.css">
<table align="center" border="0" cellpadding="0" cellspacing="0" width="70%">
<tbody><tr>
<td>
<table align="center" border="0" cellpadding="0" cellspacing="0" width="885" height="84">
<tbody>
<tr>
<td width="885">
<font color="#6BCE18">
<table border="0" cellpadding="0" cellspacing="0" width="885">
<tr>
<td height="3">
<font color="#6BCE18">
<img border="0" src="images/aramabg.gif" width="881" height="3"></td>
</tr>
<tr>
<td width="885">
<p align="center">
<?php include "inc/inc.ust.php"; ?> <img border="0" src="images/aramabg.gif" width="881" height="3"></td>
</tr>
</table>
</tr>
<tr>
<td width="885">
<p align="center">
<?php include "inc/inc.ustmenu.php"; ?></tr>
<tr>
<td width="885">
<p align="center"><?php include "inc/inc.728_90.php"; ?></tr></tbody></table>
<table border="0" cellpadding="5" cellspacing="0" height="320" width="891">
<tbody>
<tr valign="top">
<td width="173">
<table border="0" cellpadding="0" cellspacing="0" width="173" height="437">
<tr>
<td height="22" width="173" background="images/yesilbuton.jpg">
<p align="center"><font color="#FFFFFF" style="font-size: 10pt"><b>Menü</b></font></td>
</tr>
<tr>
<td height="415" width="173">
<table bgcolor="#E3E3E3" border="0" cellspacing="1" width="100%" height="414">
<tr>
<td bgcolor="#FFFFFF" height="412" width="219">
<?php include "inc/inc.sol.php"; ?> </td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td width="688">
<table border="0" cellpadding="0" cellspacing="0" width="700" height="362">
<tr>
<td height="118" width="700" colspan="2">
<table cellspacing=0 cellpadding=0 width="697" height="211">
<tr><td height="21" background="images/okuust.jpg">
<p align="left"><font size="3" color="#FFFFFF"><b> <?php echo $row_sonyazilar['baslik']; ?></b></font></td></tr>
<tr><td height="79">
<table border="0" cellpadding="0" cellspacing="0" width="694">
<tr>
<td height="35" width="434" rowspan="2"><?php include "inc/inc.468ads.php"; ?></td>
<td width="120" rowspan="2"><a href="yazdir.php?id=<?php echo $row_sonyazilar['id']; ?>"><img border="0" src="images/haber6.gif" width="76" height="32"></td>
<td width="70" rowspan="2">
<img border="0" src="images/okunma.gif" width="46" height="40"></td>
<td width="70">
<p align="center">Okunma </td>
</tr>
<tr>
<td width="70">
<center><b><font size="2" color="#808080"><?php echo $row_sonyazilar['okunma']; ?></font></b></center></td>
</tr>
</table>
<br><?php echo $row_sonyazilar['yazidevami']; ?><br><?php include "inc/inc.468ads.php"; ?><br></td></tr>
<tr><td height="19" background="images/tophdgraygradient.gif">
<img border="0" src="images/v_icon.gif" width="12" height="11"> <b>
<font size="2" color="#808080">Yorumlar</font></b></td></tr>
<tr><td height="92">
<?php if ($totalRows_yorumlar > 0) { // Show if recordset not empty ?>
<font size="2" face="Verdana">
<?php do { ?><img border="0" src="http://mizahcafe.com/images/user_comment.png" width="16" height="16">
</font>
<b><font color="#D61010" face="Verdana" size="2"> <?php echo $row_yorumlar['yazan']; ?></font></b><br>
<?php
$hedehode = $row_yorumlar['yorum'];
str_replace("<", "<", $hedehode);
str_replace(">", ">", $hedehode);
echo $hedehode; ?><font face="Tahoma" style="font-size: 9pt">
<br><br><img border="0" src="images/btn_bg.jpg" width="696" height="9"><br>
<?php } while ($row_yorumlar = mysql_fetch_assoc($yorumlar)); ?><b><font face="Tahoma">
<font size="4" color="#E2279F"></a></font></font></b>
<?php } // Show if recordset not empty ?>
<?php if ($totalRows_yorumlar == 0) { // Show if recordset empty ?> <?php } // Show if recordset empty ?><img border="0" src="images/btn_bg.jpg" width="696" height="9"><br></td></tr>
</table>
</td>
</tr>
<tr>
<td height="117" width="700" colspan="2">
<table border="0" cellpadding="0" cellspacing="0" width="697" height="121">
<tr>
<td height="121" width="232">
<font face="Tahoma" style="font-size: 9pt">
<a href="<? echo $site; ?>/yorumyap.php?id=<?php echo $row_sonyazilar['id']; ?>pop_up" onClick="window.name='<? echo $site; ?>/yorumyap.php?id=<?php echo $row_sonyazilar['id']; ?>'; window.open('<? echo $site; ?>/yorumyap.php?id=<?php echo $row_sonyazilar['id']; ?>','pop_up', 'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=505,height=330'); return false;">
<img border="0" src="images/yorum.gif" width="333" height="209"></a></td>
<td height="121" width="364">
<p align="center">
<img border="0" src="images/reklam1.gif" width="333" height="209"></td>
</tr>
</table>
</td>
</tr>
<tr>
<td height="21" width="700" background="images/tophdgraygradient.gif" colspan="2"> </td>
</tr>
<tr>
<td height="3" width="356"><?php include "inc/inc.rastgeleoku.php"; ?></td>
<td height="3" width="344"><?php include "inc/inc.okueklenenler.php"; ?></td>
</tr>
</table>
</td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody></table>
<table align="center" border="0" cellpadding="0" cellspacing="0" height="4" width="892">
<tbody><tr>
<td height="4" valign="top">
<p align="center">
<img border="0" src="images/altcizgi.jpg" width="890" height="4"></td><tr>
<td height="1" valign="top">
<p align="center">
<?php include "inc/inc.copright.php"; ?></td><html>
</html>
</html>
<?php
mysql_free_result($kategorilistesi);
mysql_free_result($yorumlar);
mysql_close();
?>