代码
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<h1>视图文件</h1>
<table>
</table>
<table border="1">
<tr>
<th>编号</th>
<th>学号</th>
<th>姓名</th>
<th>年级</th>
<th>专业</th>
<th>专业编号</th>
<th>班级</th>
<th>学习形式</th>
<th>性别</th>
</tr>
@foreach ($students as $item )
<tr>
<td>{{$item['id']}}</td>
<td>{{$item['xh']}}</td>
<td>{{$item['xingming']}}</td>
<td>{{$item['nianji']}}</td>
<td>{{$item['zhuanye']}}</td>
<td>{{$item['zhuanyebianhao']}}</td>
<td>{{$item['banji']}}</td>
<td>{{$item['xuexixingshi']}}</td>
<td>{{$item['xingbie']}}</td>
</tr>
@endforeach
</body>
</html>
运行截图