Hi there, I'm trying to develop a small project with laravel.
I create the project with composer, and a home page from master template blade. I config the route:
Route::get('/', function () {
$categories = \App\Category::all();
$articles = \App\Article::with('categories', 'user')->where('published_at', '<=', 'NOW()')->where('is_published', '=', true)->orderBy('published_at', 'DESC')->paginate(5);
return view('frontend.home', ['articles' => $articles, 'categories' => $categories]);
});
If I launch the browser localhost/blog (<--the name of my project)
I see only the files in filesystem.
I use xamp on mac
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community