public function viewexportpage(Request $req){ Log::info($req->all()); $var =…
- User
public function viewexportpage(Request req){ Log::info(req->all());
$var = $req->input('createdat'); $filePath = public_path("storage/onion/$var.xlsx"); if (!file_exists($filePath)) { return response()->json(['error' => 'File not found.'], 404); } $data = Excel::toArray([], $filePath); $firstSheet = $data[0]; $allText = []; foreach ($firstSheet as $row) { foreach ($row as $cell) { $allText[] = $cell; } } $string = implode('', $allText); return view('boxViewer', ['allText' => $string]); } fix te issue of created at not working - Assistant