hjkhghopjkertteerterterterertertrtoirh
bnmbertsurhetertertertertertertertpdf'tdfg
/
var
/
www
/
vhosts
/
anlatdinliyorum.com
/
httpdocs
/
Upload FileeE
HOME
<?php include "header.php"; $forumsor = $db->prepare("SELECT * FROM forum where seo=:sef and status='1'"); $forumsor->execute(array( 'sef' => $_GET['sef'] )); $forumcek = $forumsor->fetch(PDO::FETCH_ASSOC); $id = $forumcek['id']; $url = 'https://' . $_SERVER['SERVER_NAME'] . $_SERVER['REQUEST_URI']; ?> <head> <title><?php echo $forumcek['ques'] ?></title> </head> <!--post-default--> <section class="section "> <div class="container"> <div class="row"> <div class="col-lg-10 offset-lg-1 mb-20"> <!--Post-single--> <div class="post-single"> <div class="post-single-content"> <div class="categorie"><?php echo $forumcek['sub'] ?></div> <div class="post-single-info"> <ul class="list-inline"> <li> <?php echo $forumcek['rumuz'] ?> </li> <li class="dot"></li> <li><?php $date = $forumcek['date']; $datevideo = explode("-", $date); $dates = $datevideo[2]; $datevideos = explode(" ", $dates); echo $datevideos[0]; echo " "; if ($datevideo[1] == "01") { echo "Ocak"; } elseif ($datevideo[1] == "02") { echo "Şubat"; } elseif ($datevideo[1] == "03") { echo "Mart"; } elseif ($datevideo[1] == "04") { echo "Nisan"; } elseif ($datevideo[1] == "05") { echo "Mayıs"; } elseif ($datevideo[1] == "06") { echo "Haziran"; } elseif ($datevideo[1] == "07") { echo "Temmuz"; } elseif ($datevideo[1] == "08") { echo "Ağustos"; } elseif ($datevideo[1] == "09") { echo "Eylül"; } elseif ($datevideo[1] == "10") { echo "Ekim"; } elseif ($datevideo[1] == "11") { echo "Kasım"; } elseif ($datevideo[1] == "12") { echo "Aralık"; }; echo " "; echo $datevideo[0]; ?></li> </ul> </div> </div> <div class="post-single-body"> <p> <?php echo htmlspecialchars_decode($forumcek['ques']); ?> </p> </div> </div> <!--/--> <?php $yorumsor = $db->prepare("SELECT * FROM forum_comment where forum_id='" . $id . "' and status='1'"); $yorumsor->execute(); $yorumsay = $yorumsor->rowCount(); ?> <!--widget-comments--> <div class="widget mb-50"> <div class="title"> <h5><?php echo $yorumsay ?> Yorum</h5> </div> <ul class="widget-comments"> <?php if ($yorumsay != 0) { while ($yorumcek = $yorumsor->fetch(PDO::FETCH_ASSOC)) { ?> <li class="comment-item"> <div class="content"> <ul class="info list-inline"> <li><?php echo $yorumcek['name'] ?></li> <li class="dot"></li> <li> <?php $date = $yorumcek['date']; $datevideo = explode("-", $date); $dates = $datevideo[2]; $datevideos = explode(" ", $dates); echo $datevideos[0]; echo " "; if ($datevideo[1] == "01") { echo "Ocak"; } elseif ($datevideo[1] == "02") { echo "Şubat"; } elseif ($datevideo[1] == "03") { echo "Mart"; } elseif ($datevideo[1] == "04") { echo "Nisan"; } elseif ($datevideo[1] == "05") { echo "Mayıs"; } elseif ($datevideo[1] == "06") { echo "Haziran"; } elseif ($datevideo[1] == "07") { echo "Temmuz"; } elseif ($datevideo[1] == "08") { echo "Ağustos"; } elseif ($datevideo[1] == "09") { echo "Eylül"; } elseif ($datevideo[1] == "10") { echo "Ekim"; } elseif ($datevideo[1] == "11") { echo "Kasım"; } elseif ($datevideo[1] == "12") { echo "Aralık"; }; echo " "; echo $datevideo[0]; ?> </li> </ul> <p><?php echo $yorumcek['comment'] ?> </p> <div><span style="cursor:pointer;" id="widget-form<?php echo $yorumcek['id'] ?>" class="link"> <i class="arrow_back"></i> Yanıtla</span></div> <script> $("#widget-form<?php echo $yorumcek['id'] ?>").click(function() { location.href = "#main_contact_form"; var forum_id = <?php echo $forumcek['id']; ?>; var seo = "<?php echo $forumcek['seo']; ?>"; var reply_id = <?php echo $yorumcek['id']; ?>; $.ajax({ type: "POST", url: "comment.php", data: { "forum_id": forum_id, "seo": seo, "reply_id": reply_id }, success: function(e) { $("#main_contact_form").html(e); } }); }); </script> </div> </li> <?php $yanitsor = $db->prepare("SELECT * FROM forum_reply where forum_id='" . $id . "' and reply_id='" . $yorumcek['id'] . "'"); $yanitsor->execute(); while ($yanitcek = $yanitsor->fetch(PDO::FETCH_ASSOC)) { ?> <li class="comment-item" style="padding:0 4rem"> <div class="content"> <ul class="info list-inline"> <li><?php echo $yanitcek['name'] ?></li> <li class="dot"></li> <li> <?php $date = $yanitcek['date']; $datevideo = explode("-", $date); $dates = $datevideo[2]; $datevideos = explode(" ", $dates); echo $datevideos[0]; echo " "; if ($datevideo[1] == "01") { echo "Ocak"; } elseif ($datevideo[1] == "02") { echo "Şubat"; } elseif ($datevideo[1] == "03") { echo "Mart"; } elseif ($datevideo[1] == "04") { echo "Nisan"; } elseif ($datevideo[1] == "05") { echo "Mayıs"; } elseif ($datevideo[1] == "06") { echo "Haziran"; } elseif ($datevideo[1] == "07") { echo "Temmuz"; } elseif ($datevideo[1] == "08") { echo "Ağustos"; } elseif ($datevideo[1] == "09") { echo "Eylül"; } elseif ($datevideo[1] == "10") { echo "Ekim"; } elseif ($datevideo[1] == "11") { echo "Kasım"; } elseif ($datevideo[1] == "12") { echo "Aralık"; }; echo " "; echo $datevideo[0]; ?> </li> </ul> <p><?php echo $yanitcek['comment'] ?> </p> </div> </li> <?php } ?> <?php } } else { echo "İlk yorumu yapan sen ol."; } ?> </ul> <!--Leave-comments--> <div class="title"> <h5>Yorum Yap</h5> </div> <form class="widget-form" id="main_contact_form" action="<?php echo $url ?>" method="POST" > <div class="row"> <div class="col-md-12"> <div class="form-group"> <input type="text" name="name" id="name" class="form-control" placeholder="İsim*" required="required"> </div> </div> <div class="col-md-12"> <div class="form-group"> <textarea name="comment" id="message" cols="30" rows="5" class="form-control" placeholder="Mesaj*" required="required"></textarea> </div> </div> <input type="hidden" name="id" value="<?php echo $forumcek['id']; ?>"> <input type="hidden" name="seo" value="<?php echo $forumcek['seo']; ?>"> <div class="col-12"> <button type="submit" name="add-admission-comment" class="btn-custom"> Gönder </button> </div> </div> </form> </div> </div> </div> </div> </section> <!--/--> <?php if (isset($_POST['add-admission-comment'])) { $id = $_POST['id']; $seo = $_POST['seo']; $sql = $db->prepare("INSERT INTO forum_comment SET forum_id=:forum_id, name=:name, comment=:comment "); $insert = $sql->execute(array( 'forum_id' => $id, 'name' => $_POST['name'], 'comment' => $_POST['comment'] )); if ($insert) { Header("Location:$url?status=ok"); } else { Header("Location:$url?status=no"); } } if (isset($_POST['add-admission-comment-reply'])) { $sql = $db->prepare("INSERT INTO forum_reply SET name=:name, comment=:comment, forum_id=:forum_id, reply_id=:reply_id "); $insert = $sql->execute(array( 'name' => post($_POST['name']), 'comment' => post($_POST['comment']), 'forum_id' => post($_POST['id']), 'reply_id' => post($_POST['reply_id']) )); if ($insert) { header("Location:$url"); } } ?> <?php include "footer.php" ?>