mrjameer Posted June 28, 2007 Share Posted June 28, 2007 hi, iam using the following code to view the uploaded images. i can select the 2 different dates and can see the uploaded images between these 2 different dates.i can also delete those images also.but it is working good on localhost.but when i upload the script on server,it is not displaying the images between 2 different dates which i select,it just displays todays uploaded images.any of your help will be surely appreciated.iam thinking there is mistake in form tags <script language="Javascript"> function EgCheck() { var eg_array = document.getElementsByName("eg_array[]"); for (var i=0; i< eg_array.length; i++) { eg_array[i].checked = true; } } function writecombo($array_name, $name, $selected = "", $start = 0, $add_text = "", $add_text2 = "") { $length = count ($array_name); if (($array_name == "") || ($length == 0)){ echo "<select name=\"$name\"></select>\n"; }else{ echo "<select name=\"$name\" $add_text $add_text2>\n"; while (list($key, $val) = @each($array_name)) { if( !is_array($val) ){ $select_name = $val; $i = $key; echo " <option value=\"$i\""; if ($i == $selected){ echo " selected"; } echo ">$select_name</option>\n"; } } echo "</select>\n"; } } </script> <? if ($_POST['RenewDate']){ $renewIt=mysql_query("update admin set last_login='".time()."'"); if ($renewIt){ echo "<meta http-equiv='Refresh' Content=0;URL='imgman.php'>"; } } $eg_max=10; $limit = $eg_max; ?> <script> function gotocluster(s){ var d = s.options[s.selectedIndex].value self.location.href=d; } </script> <? if (!$start_m){ $starttime = time(); $start_y = date("Y",$starttime); $start_d = date("d",$starttime); $start_m = date("m",$starttime); } if (!$end_m){ $endtime = time(); $end_y = date("Y",$endtime); $end_d = date("d",$endtime); $end_m = date("m",$endtime); } ?> <form method="POST"> <table width="85%" border="0" align="center" cellpadding="0" cellspacing="0"> <tr valign="top"> <td><p>welcome</p></td> <td nowrap> <!-- add writecombo date here --> <? WriteCombo($month_values, "start_m",$start_m);?> / <? WriteCombo($day_values, "start_d",$start_d);?> / <input name="start_y" type="text" size="4" maxlength="4" value="<?=$start_y?>"> -Åáì- <? WriteCombo($month_values, "end_m",$end_m);?> / <? WriteCombo($day_values, "end_d",$end_d);?> / <input name="end_y" type="text" size="4" maxlength="4" value="<?=$end_y?>"> </td> <td align="right"><input type="submit" name="report" value=" view "></form> <form method="post" action="?eg=mod"><input type="submit" name="eg_mod" value="latest"></form></td> </tr> </table> <!--</form>--> <table width="85%" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td> <form method="POST"> <input type='hidden' name='start_m' value='<?=$start_m?>'> <input type='hidden' name='start_d' value='<?=$start_d?>'> <input type='hidden' name='start_y' value='<?=$start_y?>'> <input type='hidden' name='end_m' value='<?=$end_m?>'> <input type='hidden' name='end_d' value='<?=$end_d?>'> <input type='hidden' name='end_y' value='<?=$end_y?>'> <? if($_POST['report'] || $_GET['report']){ $stime = mktime(0,0,0,$start_m,$start_d,$start_y); $etime = mktime(23,59,59,$end_m,$end_d,$end_y); if($byip){ $sql = "SELECT * FROM images WHERE ipaddress='$byip'"; }else if($byuid){ $sql = "SELECT * FROM images WHERE user='$byuid'"; }else{ $sql = "SELECT * FROM images WHERE date >= $stime AND date <= $etime"; } $qr1 = mysql_query($sql); echo "total: ".mysql_num_rows($qr1)."<br>"; if($byip){ $purl = "imgman.php?report=1&byip=".$byip; }else{ $purl = "imgman.php?report=1&start_m=".$start_m."&start_d=".$start_d."&start_y=".$start_y."&end_m=".$end_m."&end_d=".$end_d."&end_y=".$end_y; } $rowcount = mysql_num_rows($qr1); $pagecount = ceil($rowcount / $limit); print "<table width=100%><td>images: " . ($pageno+1) ."</td><td align=right> <select onChange=\"gotocluster(this)\">\n <option>ÇÎÊÑ ÇáÕÝÍÉ</option>"; for($x=0; $x<$pagecount; $x++){ $p = $x + 1; $l = $x * $limit + 1; $u = $l + $limit - 1; if($u>$rowcount) $u=$rowcount; print "<option value='".$purl."&pageno=".$x."'>ÇáÕÝÍÉ $p ($l - $u)</option>\n"; } print "</select></td></table></form>"; echo "<form method='post' action='eg_del.php'> <input type='submit' value='delete'><br/><br/><a href='javascript:EgCheck();'>check</a> <table width='100%' border='1' cellspacing='4'><tr>"; $l = $pageno * $limit; $u = $l + $limit-1; $count = -1; $i = 1; $eg_count=1; $domCount = 0; while( $a = mysql_fetch_object($qr1) ){ $eg_time = date("Y/m/j h:i:s",$a->date); $count++; $row = ($count % 2)+1; if ($limit && $count < $l ) continue; if($limit && $count > $u) continue; $filen = $siteurl."/".str_replace('./', '', $att_path)."/".$a->filename; $filen = str_replace('http://','%%',$filen); $filen = str_replace('//','/',$filen); $filen = str_replace('%%','http://',$filen); //$thname = $a->thumb; $eg_explode = explode(".",$a->filename); $eg_ex = $eg_explode[1]; if(strtolower($eg_ex) == "jpg" || strtolower($eg_ex) == "gif" || strtolower($eg_ex) == "png" || strtolower($eg_ex) == "jpeg"){ echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='$filen' height=100 width=100 border=0></a><br>"; //$FName = $thname; //echo "<a href='$filen' target='_new'><img src='$filen' width=100 height=100 border=0></a><br>"; } else if(strtolower($eg_ex) == "doc") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../doc.gif' style='border-style: none;' width=50 height=50 border=0></a><br>"; } else if(strtolower($eg_ex) == "zip") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../zip.gif' style='border-style: none;' width=50 height=50 border=0></a><br>"; } else if(strtolower($eg_ex) == "txt") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../text.gif' style='border-style: none;' width=100 height=100 border=0></a><br>"; } else if(strtolower($eg_ex) == "swf") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../swf.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "mp3") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../mp3.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "avi") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../avi.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "wmv") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../wmv.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "mpg") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../mpg.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "pdf") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../pdf.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "mpeg") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../mpeg.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "ram") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../ram.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "rm") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../rm.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "wav") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../wav.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "gz") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../gzip.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "psd") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../psd.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "rar") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../rar.gif'></a><br>"; } else { echo "no image found<br>"; } if($a->user){ list($username) = mysql_fetch_array( mysql_query("SELECT username FROM users WHERE uid='".$a->user."'") ); echo " <b>ÇáãÇáß:</b> <a href='imgman.php?byuid=".$a->user."&report=1'>".$username."</a><br>"; } echo "<a href='imgman.php?byip=".$a->ipaddress."&report=1'>".$a->ipaddress."</a><br/>"; echo $eg_time."<br/>"; echo "<input type='checkbox' name='eg_array[]' value='$a->id' class='arr'>"; echo "</td>"; if ($eg_count == $eg_in_row){ echo "</tr><tr>"; $eg_count=0; } $eg_count++; } echo "</table></form>"; print "<table width=100%><td>images: " . ($pageno+1) ."</td><td align=right> <select onChange=\"gotocluster(this)\">\n <option>select</option>"; for($x=0; $x<$pagecount; $x++){ $p = $x + 1; $l = $x * $limit + 1; $u = $l + $limit - 1; if($u>$rowcount) $u=$rowcount; print "<option value='".$purl."&pageno=".$x."'>ÇáÕÝÍÉ $p ($l - $u)</option>\n"; } print "</select></td></table>"; }elseif($_GET['eg'] == "mod"){ $eg_sqlmod=mysql_query("select last_login from admin") or die (mysql_error()); $sqlmod=mysql_fetch_array($eg_sqlmod); // Paging ----------------------- if(!(isset($page))) { $page=1; } else { $page=$_GET['page']; } // Max_Per_Page $max=$eg_max; // from page to page $from=($max*$page)-$max; $paging=mysql_query("select id from images where date>='$sqlmod[last_login]'"); $nums=mysql_num_rows($paging); $pages=ceil($nums/$max); // -------------------------------- $sql="select * from images where date>='$sqlmod[last_login]' limit $from,$max"; $qr1 = mysql_query($sql); echo "<input type='submit' name='RenewDate' value='ÊÌÏíÏ ÊÇÑíÎ ÂÎÑ ÒíÇÑÉ'>"; //</form>"; echo "<form method='post' name='myf' action='eg_del.php'> <input type='submit' value='del'><br/><br/> <a href='javascript:EgCheck();'>ÊÍÏíÏ Çáßá</a> <table width='100%' border='1' cellspacing='4'><tr>"; $l = $pageno * $limit; $u = $l + $limit-1; $count = -1; $i = 1; $eg_count=1; $eg_a=0; $domCount = 0; while( $a = mysql_fetch_object($qr1) ){ $eg_time = date("Y/m/j h:i:s",$a->date); $count++; $row = ($count % 2)+1; if ($limit && $count < $l ) continue; if($limit && $count > $u) continue; $filen = $siteurl."/".str_replace('./', '', $att_path)."/".$a->filename; $filen = str_replace('http://','%%',$filen); $filen = str_replace('//','/',$filen); $filen = str_replace('%%','http://',$filen); //$thname = $a->thumb; $eg_explode = explode(".",$a->filename); $eg_ex = $eg_explode[1]; if(strtolower($eg_ex) == "jpg" || strtolower($eg_ex) == "gif" || strtolower($eg_ex) == "png" || strtolower($eg_ex) == "jpeg"){ // $FName = $thname; echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='$filen' width=100 height=100 border=0></a><br>"; } else if(strtolower($eg_ex) == "doc") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../doc.gif' style='border-style: none;' width=50 height=50 border=0></a><br>"; } else if(strtolower($eg_ex) == "zip") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../zip.gif' style='border-style: none;' width=50 height=50 border=0></a><br>"; } else if(strtolower($eg_ex) == "txt") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../text.gif' style='border-style: none;' width=100 height=100 border=0></a><br>"; } else if(strtolower($eg_ex) == "swf") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../swf.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "mp3") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../mp3.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "avi") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../avi.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "wmv") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../wmv.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "mpg") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../mpg.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "pdf") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../pdf.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "mpeg") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../mpeg.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "ram") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../ram.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "rm") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../rm.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "wav") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../wav.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "gz") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../gzip.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "psd") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../psd.gif' style='border-style: none;' border=0></a><br>"; } else if(strtolower($eg_ex) == "rar") { echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../rar.gif'></a><br>"; } else { echo "<td align='center'>"; echo "no image found<br>"; } /* echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../$filen' border=0></a><br>"; echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../$filen' border=0></a><br>";*/ if($a->user){ list($username) = mysql_fetch_array( mysql_query("SELECT username FROM users WHERE uid='".$a->user."'") ); echo " <b>ÇáãÇáß:</b> <a href='imgman.php?byuid=".$a->user."&report=1'>".$username."</a><br>"; } echo "<a href='imgman.php?byip=".$a->ipaddress."&report=1'>".$a->ipaddress."</a><br>"; echo $eg_time."<br/>"; echo "<input type='checkbox' name='eg_array[]' value='$a->id' class='arr'>"; echo "</td>"; if ($eg_count == $eg_in_row){ echo "</tr><tr>"; $eg_count=0; } $eg_count++; $eg_a++; } echo "</tr></table></form> <center>"; } // paging ---------------------------------------------------- for($i=1;$i<=$pages;$i++) { if($page==$i) { echo"[$i]"; } else { echo "<a href=".$PHP_SELF."?eg=mod&page=$i>[$i]</a> "; } } // ------------------------------------------------------------ ?> <!-- </form>--> </td> </tr> </table> <? include("siteadmin/footer.php"); ?> Quote Link to comment Share on other sites More sharing options...
trq Posted June 28, 2007 Share Posted June 28, 2007 Seriously, you need to narrow the problem down some. No one is going to sift through all that. Quote Link to comment Share on other sites More sharing options...
mrjameer Posted June 28, 2007 Author Share Posted June 28, 2007 hi, sorry,now i filtered some code. <script language="Javascript"> function EgCheck() { var eg_array = document.getElementsByName("eg_array[]"); for (var i=0; i< eg_array.length; i++) { eg_array[i].checked = true; } } function writecombo($array_name, $name, $selected = "", $start = 0, $add_text = "", $add_text2 = "") { $length = count ($array_name); if (($array_name == "") || ($length == 0)){ echo "<select name=\"$name\"></select>\n"; }else{ echo "<select name=\"$name\" $add_text $add_text2>\n"; while (list($key, $val) = @each($array_name)) { if( !is_array($val) ){ $select_name = $val; $i = $key; echo " <option value=\"$i\""; if ($i == $selected){ echo " selected"; } echo ">$select_name</option>\n"; } } echo "</select>\n"; } } </script> <? if ($_POST['RenewDate']){ $renewIt=mysql_query("update admin set last_login='".time()."'"); if ($renewIt){ echo "<meta http-equiv='Refresh' Content=0;URL='imgman.php'>"; } } $eg_max=10; $limit = $eg_max; ?> <script> function gotocluster(s){ var d = s.options[s.selectedIndex].value self.location.href=d; } </script> <? if (!$start_m){ $starttime = time(); $start_y = date("Y",$starttime); $start_d = date("d",$starttime); $start_m = date("m",$starttime); } if (!$end_m){ $endtime = time(); $end_y = date("Y",$endtime); $end_d = date("d",$endtime); $end_m = date("m",$endtime); } ?> <form method="POST"> <table width="85%" border="0" align="center" cellpadding="0" cellspacing="0"> <tr valign="top"> <td><p>welcome</p></td> <td nowrap> <!-- add writecombo date here --> <? WriteCombo($month_values, "start_m",$start_m);?> / <? WriteCombo($day_values, "start_d",$start_d);?> / <input name="start_y" type="text" size="4" maxlength="4" value="<?=$start_y?>"> -Åáì- <? WriteCombo($month_values, "end_m",$end_m);?> / <? WriteCombo($day_values, "end_d",$end_d);?> / <input name="end_y" type="text" size="4" maxlength="4" value="<?=$end_y?>"> </td> <td align="right"><input type="submit" name="report" value=" view "></form> <form method="post" action="?eg=mod"><input type="submit" name="eg_mod" value="latest"></form></td> </tr> </table> <!--</form>--> <table width="85%" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td> <form method="POST"> <input type='hidden' name='start_m' value='<?=$start_m?>'> <input type='hidden' name='start_d' value='<?=$start_d?>'> <input type='hidden' name='start_y' value='<?=$start_y?>'> <input type='hidden' name='end_m' value='<?=$end_m?>'> <input type='hidden' name='end_d' value='<?=$end_d?>'> <input type='hidden' name='end_y' value='<?=$end_y?>'> <? if($_POST['report'] || $_GET['report']){ $stime = mktime(0,0,0,$start_m,$start_d,$start_y); $etime = mktime(23,59,59,$end_m,$end_d,$end_y); if($byip){ $sql = "SELECT * FROM images WHERE ipaddress='$byip'"; }else if($byuid){ $sql = "SELECT * FROM images WHERE user='$byuid'"; }else{ $sql = "SELECT * FROM images WHERE date >= $stime AND date <= $etime"; } $qr1 = mysql_query($sql); echo "total: ".mysql_num_rows($qr1)."<br>"; if($byip){ $purl = "imgman.php?report=1&byip=".$byip; }else{ $purl = "imgman.php?report=1&start_m=".$start_m."&start_d=".$start_d."&start_y=".$start_y."&end_m=".$end_m."&end_d=".$end_d."&end_y=".$end_y; } $rowcount = mysql_num_rows($qr1); $pagecount = ceil($rowcount / $limit); print "<table width=100%><td>images: " . ($pageno+1) ."</td><td align=right> <select onChange=\"gotocluster(this)\">\n <option>ÇÎÊÑ ÇáÕÝÍÉ</option>"; for($x=0; $x<$pagecount; $x++){ $p = $x + 1; $l = $x * $limit + 1; $u = $l + $limit - 1; if($u>$rowcount) $u=$rowcount; print "<option value='".$purl."&pageno=".$x."'>ÇáÕÝÍÉ $p ($l - $u)</option>\n"; } print "</select></td></table></form>"; echo "<form method='post' action='eg_del.php'> <input type='submit' value='delete'><br/><br/><a href='javascript:EgCheck();'>check</a> <table width='100%' border='1' cellspacing='4'><tr>"; $l = $pageno * $limit; $u = $l + $limit-1; $count = -1; $i = 1; $eg_count=1; $domCount = 0; while( $a = mysql_fetch_object($qr1) ){ $eg_time = date("Y/m/j h:i:s",$a->date); $count++; $row = ($count % 2)+1; if ($limit && $count < $l ) continue; if($limit && $count > $u) continue; $filen = $siteurl."/".str_replace('./', '', $att_path)."/".$a->filename; $filen = str_replace('http://','%%',$filen); $filen = str_replace('//','/',$filen); $filen = str_replace('%%','http://',$filen); //$thname = $a->thumb; $eg_explode = explode(".",$a->filename); $eg_ex = $eg_explode[1]; if(strtolower($eg_ex) == "jpg" || strtolower($eg_ex) == "gif" || strtolower($eg_ex) == "png" || strtolower($eg_ex) == "jpeg"){ echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='$filen' height=100 width=100 border=0></a><br>"; //$FName = $thname; //echo "<a href='$filen' target='_new'><img src='$filen' width=100 height=100 border=0></a><br>"; } else { echo "no image found<br>"; } if($a->user){ list($username) = mysql_fetch_array( mysql_query("SELECT username FROM users WHERE uid='".$a->user."'") ); echo " <b>ÇáãÇáß:</b> <a href='imgman.php?byuid=".$a->user."&report=1'>".$username."</a><br>"; } echo "<a href='imgman.php?byip=".$a->ipaddress."&report=1'>".$a->ipaddress."</a><br/>"; echo $eg_time."<br/>"; echo "<input type='checkbox' name='eg_array[]' value='$a->id' class='arr'>"; echo "</td>"; if ($eg_count == $eg_in_row){ echo "</tr><tr>"; $eg_count=0; } $eg_count++; } echo "</table></form>"; print "<table width=100%><td>images: " . ($pageno+1) ."</td><td align=right> <select onChange=\"gotocluster(this)\">\n <option>select</option>"; for($x=0; $x<$pagecount; $x++){ $p = $x + 1; $l = $x * $limit + 1; $u = $l + $limit - 1; if($u>$rowcount) $u=$rowcount; print "<option value='".$purl."&pageno=".$x."'>ÇáÕÝÍÉ $p ($l - $u)</option>\n"; } print "</select></td></table>"; }elseif($_GET['eg'] == "mod"){ $eg_sqlmod=mysql_query("select last_login from admin") or die (mysql_error()); $sqlmod=mysql_fetch_array($eg_sqlmod); // Paging ----------------------- if(!(isset($page))) { $page=1; } else { $page=$_GET['page']; } // Max_Per_Page $max=$eg_max; // from page to page $from=($max*$page)-$max; $paging=mysql_query("select id from images where date>='$sqlmod[last_login]'"); $nums=mysql_num_rows($paging); $pages=ceil($nums/$max); // -------------------------------- $sql="select * from images where date>='$sqlmod[last_login]' limit $from,$max"; $qr1 = mysql_query($sql); echo "<input type='submit' name='RenewDate' value='ÊÌÏíÏ ÊÇÑíÎ ÂÎÑ ÒíÇÑÉ'>"; //</form>"; echo "<form method='post' name='myf' action='eg_del.php'> <input type='submit' value='del'><br/><br/> <a href='javascript:EgCheck();'>ÊÍÏíÏ Çáßá</a> <table width='100%' border='1' cellspacing='4'><tr>"; $l = $pageno * $limit; $u = $l + $limit-1; $count = -1; $i = 1; $eg_count=1; $eg_a=0; $domCount = 0; while( $a = mysql_fetch_object($qr1) ){ $eg_time = date("Y/m/j h:i:s",$a->date); $count++; $row = ($count % 2)+1; if ($limit && $count < $l ) continue; if($limit && $count > $u) continue; $filen = $siteurl."/".str_replace('./', '', $att_path)."/".$a->filename; $filen = str_replace('http://','%%',$filen); $filen = str_replace('//','/',$filen); $filen = str_replace('%%','http://',$filen); //$thname = $a->thumb; $eg_explode = explode(".",$a->filename); $eg_ex = $eg_explode[1]; if(strtolower($eg_ex) == "jpg" || strtolower($eg_ex) == "gif" || strtolower($eg_ex) == "png" || strtolower($eg_ex) == "jpeg"){ // $FName = $thname; echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='$filen' width=100 height=100 border=0></a><br>"; } else { echo "<td align='center'>"; echo "no image found<br>"; } /* echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../$filen' border=0></a><br>"; echo "<td align='center'>"; echo "<a href='$filen' target='_new'><img src='../$filen' border=0></a><br>";*/ if($a->user){ list($username) = mysql_fetch_array( mysql_query("SELECT username FROM users WHERE uid='".$a->user."'") ); echo " <b>ÇáãÇáß:</b> <a href='imgman.php?byuid=".$a->user."&report=1'>".$username."</a><br>"; } echo "<a href='imgman.php?byip=".$a->ipaddress."&report=1'>".$a->ipaddress."</a><br>"; echo $eg_time."<br/>"; echo "<input type='checkbox' name='eg_array[]' value='$a->id' class='arr'>"; echo "</td>"; if ($eg_count == $eg_in_row){ echo "</tr><tr>"; $eg_count=0; } $eg_count++; $eg_a++; } echo "</tr></table></form> <center>"; } // paging ---------------------------------------------------- for($i=1;$i<=$pages;$i++) { if($page==$i) { echo"[$i]"; } else { echo "<a href=".$PHP_SELF."?eg=mod&page=$i>[$i]</a> "; } } // ------------------------------------------------------------ ?> <!-- </form>--> </td> </tr> </table> <? include("siteadmin/footer.php"); ?> Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.