ホームページ >バックエンド開発 >PHPチュートリアル >如何让记录集“内容不重复出现”

如何让记录集“内容不重复出现”

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBオリジナル
2016-06-13 11:27:27980ブラウズ

怎么让记录集“内容不重复出现”

<?php  require_once('Conn/hx98.php'); ?><br><?php <br />if (!function_exists("GetSQLValueString")) {<br>function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "") <br>{<br>  if (PHP_VERSION     $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;<br>  }<br><br>  $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);<br><br>  switch ($theType) {<br>    case "text":<br>      $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";<br>      break;    <br>    case "long":<br>    case "int":<br>      $theValue = ($theValue != "") ? intval($theValue) : "NULL";<br>      break;<br>    case "double":<br>      $theValue = ($theValue != "") ? doubleval($theValue) : "NULL";<br>      break;<br>    case "date":<br>      $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";<br>      break;<br>    case "defined":<br>      $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;<br>      break;<br>  }<br>  return $theValue;<br>}<br>}<br><br>$maxRows_hx = 10;<br>$pageNum_hx = 0;<br>if (isset($_GET['pageNum_hx'])) {<br>  $pageNum_hx = $_GET['pageNum_hx'];<br>}<br>$startRow_hx = $pageNum_hx * $maxRows_hx;<br> mysql_query("set names utf8");<br>mysql_select_db($database_hx98, $hx98);<br>$query_hx = "SELECT * FROM content_publish ORDER BY content_id DESC";<br>$query_limit_hx = sprintf("%s LIMIT %d, %d", $query_hx, $startRow_hx, $maxRows_hx);<br>$hx = mysql_query($query_limit_hx, $hx98) or die(mysql_error());<br>$row_hx = mysql_fetch_assoc($hx);<br><br><br><br>if (isset($_GET['totalRows_hx'])) {<br>  $totalRows_hx = $_GET['totalRows_hx'];<div class="clear">
                 
              
              
        
            </div>
声明:
この記事の内容はネチズンが自主的に寄稿したものであり、著作権は原著者に帰属します。このサイトは、それに相当する法的責任を負いません。盗作または侵害の疑いのあるコンテンツを見つけた場合は、admin@php.cn までご連絡ください。