search

Home  >  Q&A  >  body text

How to implement PHP to read data from SQL to achieve carousel effect

How to display data one by one? For example: There are three pieces of data in my database

name 张三、李四、王五  age 20、21、22
如何在web 页面 逐条输出 张三 20   李四 21  王五 22  即输出张三 20 停顿2秒 换成  输出 李四 21  停顿2秒 换成输出 王五 22  三条数据不同时出现。
范珺范珺2326 days ago1385

reply all(2)I'll reply

  • jesse

    jesse2018-09-06 14:59:37

    First of all, you need to have a static page. This page can meet the carousel effect you mentioned, but the data is static, which you write in the code. To dynamically retrieve data from the database, you need to use PHP connects to the database to get the result set and displays the output on the page

    reply
    0
  • 阿尔托莉雅

    阿尔托莉雅2018-09-01 15:36:07

    Use Timeline

    reply
    0
  • 范珺

    How to make this thing? Is it written in html or php?

    范珺 · 2018-09-01 16:28:21
  • Cancelreply