Location: PHPKode > scripts > Create Your Own Directory > cms/admin/ereview.php
<?php
include "authheader.php";

if($block != true)
{
?>

<!-- Welcome to the scripts database of HIOX INDIA      -->
<!-- This tool is developed and a copyright             -->
<!-- product of HIOX INDIA.				        -->
<!-- For more information visit http://www.hscripts.com -->

<html>
<head>
<style>
.ta{background-color: ffff44;}
.rad{color:red; font-weight:bold; background-color: ffff44;}
.head{font-size: 17px; color: white; font-family: verdana, arial, san-serif;}
.links{font-size: 13px; color: white; font-family: verdana, arial, san-serif; text-decoration:none;}
.maintext{font-size: 13px; color: #fefefe; font-family: verdana, arial, san-serif; padding:20px;}
</style>
</head>
<body style="margin: 0px;">
<?php include "heade.php" ?>

<table width=790 height=100% cellpadding=0 cellspacing=0 align=center>
<tr><td align=center>


<tr height=100%><td class=maintext valign=top>
<div align=center style="color: 000000">

<?php

	$url = $_POST['url'];
	$start = $_GET['start'];
	if($start == "")
		$start = 0;
	$id = $_GET['id'];

	// will go to review.php for last process
	if($id != "")
	{
		$res2 = mysql_query("select * from comments where id like '$id'", $link);
		if($line = mysql_fetch_array($res2, MYSQL_ASSOC))
		{
			$name = $line['name'];
			$com = $line['review'];
			$url = $line['url'];
			$email = $line['email'];

			echo "<table align=center bgcolor=white cellpadding=0 cellspacing=0>";
			echo "<form name=de action=index.php method=post>";
			echo "<tr><td>Name</td><td><input type=text name=nam value=$name size=40></input></td></tr>";
			echo "<tr><td>Email</td><td><input type=text name=email value=$email size=40></input></td></tr>";
			echo "<tr><td>Comment</td><td><textarea name=com rows=5 cols=45>$com</textarea></td></tr>";
			echo "<tr><td> </td><td> <br> </td></tr>";
			echo "<tr><td> </td><td> 
			<input name=url type=hidden value=$url>
			<input name=id type=hidden value=$id>
			<input name=rev type=hidden value=\"true\">
			<input name=submit type=submit value=submit>
			<input name=submit type=submit value=delete> </td></tr>";
			echo "</form>";
		}
	}
	else if($url != "")
	{
		$next = $start+10;
		$prev = $start-10;
		if($prev < 10)
			$prev=0;
		echo "<a href=?start=$prev>&lt;&lt;PREV</a>   Showing $start to $next <a href=?start=$next>NEXT&gt;&gt;</a> Reviews
		for the url <br> $url <br><br>";

		$str = "select * from comments where status like 'yes' and url like '$url' order by dat limit $start,10";
		//echo "$str";
		$res2 = mysql_query($str, $link);
		echo "<table bgcolor=white cellpadding=0 cellspacing=0 width=98% border=1
		style=\"color: 343434; font-size: 14px;\"  align=center>";
		echo "<tr align=center bgcolor=000000 style=\"color: ffffff;\"><td>NAME</td><td>Message</td><td> URL </td></tr>";
		while($line = mysql_fetch_array($res2, MYSQL_ASSOC))
		{
			$id = $line['id'];
			$name = $line['name'];
			$com = $line['review'];
			$url = $line['url'];
			$len = strlen($url);
			if($len > 30)
			{
				$url1 = substr($url,$len-30,$len);
				$url1 = ".......".$url1;
			}
			else{
				$url1 = $url;
			}

			echo "<tr align=center bgcolor=#FFFFFF><td>$name</td><td>$com</td>
			<td><a target=_blank  href=$url style=\"text-decoration: none; color: 0000ff;\"> $url1 </td>
			<td><b><a href=\"?id=$id\" style=\"text-decoration: none; color: green;\">review</a></b></td></tr>";
		}

	}
	else
	{
		?>
		<form style="margin: 0px;" name=ss action=ereview.php method=POST>
		<input name=url type=hidden>
		</form>
		<script language=javascript>
		function usub(sub)
		{
			document.ss.url.value = sub;
			document.ss.submit();
		}
		</script>
		<?php
		$next = $start+10;
		$prev = $start-10;
		if($prev < 10)
			$prev=0;
		echo "<a href=?start=$prev>&lt;&lt;PREV</a>   Showing $start to $next Pages <a href=?start=$next>NEXT&gt;&gt;</a>";
		$res2 = mysql_query("select url,count(*) as coun from comments group by url limit $start,10", $link);

		echo "<table bgcolor=white cellpadding=0 cellspacing=0 width=98% 
		style=\"color: 343434; font-size: 14px;\"  align=center>";
		echo "<tr align=center bgcolor=#b0e2ff><td>URL</td><td>Total Reviews </td></tr>";
		while($line = mysql_fetch_array($res2, MYSQL_ASSOC))
		{
			$url = $line['url'];
			$cou = $line['coun'];
			$len = strlen($url);
			if($len > 30)
			{
				$url1 = substr($url,$len-30,$len);
				$url1 = ".......".$url1;
			}
			else{
				$url1 = $url;
			}

			echo "<tr align=center bgcolor=#FFFFFF>
			<td><b><a target=_blank href=\"$url\" style=\"text-decoration: none; color: green;\">$url1</a></b></td>
			<td><a onclick=usub('$url') style=\"cursor: pointer;text-decoration: none; color: 0000ff;\"> $cou </td></tr>";
		}
	}
	echo "</table>";
?>

</div>
</td></tr>
<!-- content row -->

<tr><td width=100% align=right>
a product by &copy; <a href="http://www.hscripts.com" 
style="font-size: 14px; color: 347777; text-decoration:none;">hscripts.com</a> 
&nbsp; &nbsp; &nbsp; &nbsp;
</td></tr>
</table>
<!-- main table -->

</td></tr>
</table>
<tr><td height=20 bgcolor=white>
</td></tr></table>

</body>
</html>

<!-- Welcome to the scripts database of HIOX INDIA      -->
<!-- This tool is developed and a copyright             -->
<!-- product of HIOX INDIA.				        -->
<!-- For more information visit http://www.hscripts.com -->

<?php
}
?>
Return current item: Create Your Own Directory