Answer the question
In order to leave comments, you need to log in
How to get an array from PHP keys?
From js to php, an array comes in the form of a string, because it is sent like this.
const a = [{3:5},{1:2}];
JSON.stringify(a)
$arr = [3,1];
$goods = mysqli_query($connection, "SELECT * FROM `goods` WHERE `id` in $arr");
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question