HTML table using MySQLi and PHP

后端 未结 2 669
伪装坚强ぢ
伪装坚强ぢ 2020-11-28 16:40

I\'m trying to make a table connected to my database so I can use the information in that database.

I think I\'m on the right way, but currently the table only displ

2条回答
  •  盖世英雄少女心
    2020-11-28 17:42

    Your code gets only one row from table, you need loop your results.
    Try this code:

    $results = mysqli_query($conn,$sql);
    
    while($row = mysqli_fetch_array($results))
    {
      //do smth
    }
    

提交回复
热议问题