Home > Article > Backend Development > PHP connects to MySQL to perform add, delete, modify and query operations
This article mainly introduces the method of PHP connecting to MySQL to perform add, delete, modify and query operations. It has a very good reference value. Let’s take a look at it with the editor.
Not much to say Please look at the code:
# Fetch_all () Back to all arrays
# FETCH_ROW ()
# FETCH_ASSOC () Return to the associated array FETCH_OBJECT () Return to the object # FETCH_ARAY () The array of arrays returned has both indexes and associated steals Delete, add, and modify operations代号 | 姓名 | 性别 | 民族 | 生日 |
{$attr[0]} | {$attr[1]} | {$attr[2]} | {$attr[3]} | {$attr[4]} |