Answers for "Warning: Undefined array key "index_no" in C:\xampp\htdocs\true\student\reports.php on line 54 Fatal error: Uncaught TypeError: mysqli_fetch_array():"

PHP
0

Warning: Undefined array key "index_no" in C:\xampp\htdocs\true\student\reports.php on line 54 Fatal error: Uncaught TypeError: mysqli_fetch_array():

Warning: Undefined array key "index_no" in C:\xampp\htdocs\true\student\reports.php on line 54

Fatal error: Uncaught TypeError: mysqli_fetch_array(): Argument #1 ($result) must be of type mysqli_result, bool given in C:\xampp\htdocs\true\student\reports.php:56 Stack trace: #0 C:\xampp\htdocs\true\student\reports.php(56): mysqli_fetch_array(false) #1 {main} thrown in C:\xampp\htdocs\true\student\reports.php on line 56
Posted by: Guest on April-20-2022
0

Warning: Undefined array key "index_no" in C:\xampp\htdocs\true\student\reports.php on line 54 Fatal error: Uncaught TypeError: mysqli_fetch_array():

<?php
				$sql ="SELECT users.index_no,matokeo.CMT05101,matokeo.CMT05102,matokeo.CMT05103,matokeo.CMT05104,matokeo.CMT05105,matokeo.GPA,matokeo.Remarks FROM users INNER JOIN matokeo ON users.index_no = matokeo.index_no WHERE type='student',index_no ='".$_SESSION['index_no']."";
				$query = mysqli_query($con,$sql);
				while ($row2 =mysqli_fetch_array($query)) {?>
				   <tr style="text-align:center;">
				   	<td><?php echo $row2['index_no'];?></td>
				   	<td><?php echo $row2['CMT05101'];?></td>
				   	<td><?php echo $row2['CMT05102'];?></td>
				   	<td><?php echo $row2['CMT05103'];?></td>
				   	<td><?php echo $row2['CMT05104'];?></td>
				   	<td><?php echo $row2['CMT05105'];?></td>
				   	<td><?php echo $row2['GPA'];?></td>
				   	<td><?php echo $row2['Remarks'];?></td>
				   </tr>
				<?php }?>
Posted by: Guest on April-20-2022

Code answers related to "Warning: Undefined array key "index_no" in C:\xampp\htdocs\true\student\reports.php on line 54 Fatal error: Uncaught TypeError: mysqli_fetch_array():"

Browse Popular Code Answers by Language