GetData($sql); while ($res) { 1 } $obj = mysqli_fetch_object($res); ?> ">
输入banner图图片脚本导航/分类

php里面如何循环嵌入html元素

php里面怎么循环嵌入html元素

  • 中奖信息



      $sql = "select * from t_activity where MemberID='$memberID'";
      $res = $db->GetData($sql);

      while ($res)
      {
    • 1


    • }
      $obj = mysqli_fetch_object($res);
      ?>





  • 如上面,从数据库取出数据来后,怎么从数据库结果集中循环输出想要的数据在html的li里面?
    ------解决方案--------------------

  • 中奖信息



      $sql = "select * from t_activity where MemberID='$memberID'";
      $res = $db->GetData($sql);

      while ($obj = mysqli_fetch_object($res))
      {
      ?>
    • 字段 ;?>

    • }

      ?>