PHP
0
Вклад в тег
foreach($carts as $cart){
$data = [
"title" => $cart['title'],
"description" => $cart['description'],
"image" => $cart['image'],
"dimensions" => $cart['dimension'],
"data" => date('Y-m-d'),
"category_id" => $cart['category_id'],
"user_id" => $this->auth->getUserId(),
"amount" => $cart['amount'],
"price" => $cart['price'],
];
И тут уже само PDO
}