Response & #39;); $ arrContsexplode (& quot; n & quot;, $ cc); foreach ($ arrContsas $ ccc) {$ cccjson_decode (stripslashes ($ ccc ), true );... processing json inserts into the database} & quot; the mysql table id is auto-incrementing and $ query & quot; INSERTINTOlogsSET mysqlphpforeach is not inserted
$ Cc = file_get_contents ('data/phone_log.txt '); $ arrConts = explode ("\ n", $ cc); foreach ($ arrConts as $ ccc) {$ ccc = json_decode (stripslashes ($ ccc), true );... processing json inserts into the database}
The id of the mysql table is auto-increment and is not inserted.
$ Query = "insert into logs SET name = '". $ ccc [name]. "', state = 1, domain = '". $ domain. "', data = '". $ new. "'";
Mysql_query ($ query );
Open the text to obtain the json Array, and then process it. However, when multiple rows are used, only the first data is inserted at a time.