爱玺玺

爱玺玺的生活日记本。wx:lb87626

php+mysql select 搜索字段时加入其它常量

 $sql = "select msgid, userid, sender, msgtxt, stime, 'interval' as c from u_msg where ((userid='$uid' and sender = '$otheruid') or (userid='$otheruid' and sender = '$uid'))  order by stime asc";
$iden=mysql_query($sql);
while($rsin=mysql_fetch_array($iden)){
  echo $rsin["stime"]." ".$rsin["c"]."<br>";
}

发表评论:

Powered By Z-BlogPHP 1.4 Deeplue Build 150101

Copyright Your WebSite.Some Rights Reserved.

蜀ICP备11021721号-5