foreach($studentAssProg as $data){
if($data['assignmentID']==3){
echo $data['assProgLevel'];
}
}
Extra data from an array
-
08-07-2023 - |
Pergunta
I have create this array:
$studentAssProg[]=array('studentID'=> $studentID,'assignmentID'=>$assignmentID,'assProgLevel'=>$progress);
what would be the best way to print the progressLevel, for each student where assignmentID = '3' ?
Solução
Outras dicas
foreach($studentAssProg as $d) :
if($d['assignmentID'] == 3)
echo $d['assProgLevel'];
endforeach;
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow