Using same MySQL Connection in different PHP pages

前端 未结 5 2002
一生所求
一生所求 2021-01-19 03:46

I am creating a simple Web Application in PHP for my college project. I am using the MySQL database.

I connect to the database in login.php. After connection I assig

5条回答
  •  执念已碎
    2021-01-19 04:21

    The second request may not be served by the same web server process as the first, which means that you will have a completely separate set of database resources. You'll need to connect again in this new process in order to run queries.

提交回复
热议问题