[Solved] Create a simple php array using mysql rows… [closed]


Here’s a technic :

<?php

// Query the database
SELECT product_id FROM product

// Loop
$Products = array();
while(){
    $Products[] = $Row->product_id;
}

print_r($Products);

?>

Try something by yourself. Use PDO extension to create your query and then use the method fetch to get your data in the loop.

0

solved Create a simple php array using mysql rows… [closed]