In ur controller ur passing entry and in the blade file ur trying to loop through variable called entries hence it fails to identify the variable entry. Below is the updated controller method.
public function showUpload(Entries $entry)
{
$entries = Entries::with('entrys')->where('user_id', '=', Auth::user()->id)->get();
return view('viewentry', compact('entries'));
}
I updated the controller code to what you suggested but it still isn't working as it should.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community