| Server IP : 93.86.61.54 / Your IP : 216.73.216.60 Web Server : Apache/2.4.62 (Ubuntu) System : Linux rasin.ddns.net 6.8.0-124-generic #124~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue May 26 21:05:19 UTC x86_64 User : www-data ( 33) PHP Version : 8.4.22 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /var/www/html/projects/news_portal/ |
Upload File : |
<?php
session_start();
include('config.php');
$email = $_SESSION['email'];
$n_id=$_SESSION['n_id'];
$que="SELECT * FROM register where email='$email'";
$row1=mysql_query($que) or die(mysql_error());
$res=mysql_fetch_array($row1);
$id=$res['id'];
$que1 = "SELECT * FROM comments where user_id='$id' and news_id='$n_id' ORDER BY c_id DESC";
$result=mysql_query($que1) or die(mysql_error());
while($row=mysql_fetch_array($result)){
$d=$row['comment_date'];
$date=date_create($d);
$com_date=date_format($date,"d-m-Y");
echo "<div class='comments_content'>";
echo "<h4 style='text-align:right;'><a href='deleteComment.php?id=" . $row['c_id'] . "' title='remove'> X</a></h4>";
/*echo "<h4 style='color:blue;'>" . $res['fname'] ." ". $res['lname'] ."</h4>";*/
echo "<h6 style='color:grey'>" . $com_date. "</h6></br>";
echo "<h5 style='color:#233903;'>" . $row['message'] . "</h5>";
echo "</div>";
}
?>