Hello :)
In the articles controller you could extract this part of query in a scope
::where('title', 'like', '%' . $qry . '%') ->orWhere('short_description', 'like', '%' . $qry . '%') ->orWhere('content', 'like', '%' . $qry . '%')
In the blade, you could extract what is inside the foreach in another blade
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community