Skip to content

How to save the variable from query in mysql with PHP?

$result = $db->query('Select `Name`, `Age`, `Color` from `People` ');
while ($rows = $result->fetch()){
$Name = $rows['Name'];
$Age = $rows['Age'];
$Color = $rows['Color'];
}
See also  Java code snippet - How to sort arraylist?

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.