/** * Display the specified resource. * * @param int $id * @return \Illuminate\Http\Response */ public function show($id) { $std = student::where('regNo', '=', $id)->first(); $dep = department::where('student_regNo', '=', $id)->first(); $caf = cafeteria::where('student_regNo', '=', '78699')->first(); $lib = library::where('student_regNo', '=', '78699')->first(); $ext = extraactiv::where('student_regNo', '=', '78699')->first(); $fa = fa::where('student_regNo', '=', '78699')->first(); $fin = finance::where('student_regNo', '=', '78699')->first(); $gam = games::where('student_regNo', '=', '78699')->first(); $html = PDF::make($std, $dep, $caf, $lib, $ext, $fa, $fin, $gam); $mpdf = new mpdf(); $mpdf->WriteHTML($html); $mpdf->Output(); // $allpeople = student::where('regNo','=',$id)->first(); // echo $allpeople->stdFname; }