Hi all I'm new to oop and I wanted to find out how to return multiple array variable from a function. Please see below for an explanation
function getvalues(){
//do mysql query using pdo
while($row = $getmostvalues->fetch(PDO::FETCH_ASSOC)) {
$value[] = $row['val1'];
$time[] = $row['time'];
}
}
how can I retrieve and use say $value[0] in my php code after calling getvalues();