0
votes

I am new to the laravel framework. I started a tutorial video on tuts, and followed the directions exactly. I setup laravel and was able to access localhost/laravel/public just fine. I even changed routes.php and was still able to access localhost/laravel/public. However, the next step in the tutorial was to create a new Route. my new Route looks like this

Route::get('post', 'PostController@show');

I then created a new controller called PostController. The file looks like this:

<?php

class PostController extends BaseController
{
    public function show()
    {
        return View::make('post.show');
    }
}

Next, the tutorial asked me to create a show.php in a new directory called "post". Then when I access localhost/laravel/public/post the "show.php" should appear. Instead I receive an error that says

"The requested URL /laravel/public/post was not found on this server"

I am running Apache/2.4.9 (win64) PHP/5.5.12 Server at localhost Port 80

Once again, I followed the exact instructions from tutsplus.

1
What is the DocumentRoot of your vhost setup to point to? What happens if you try to visit localhost/laravel/post instead? Also, can you post the link to the tutorial you're trying to follow?Jeff Lambert
here is a link to the tutorial code.tutsplus.com/articles/…Eddie Greathouse

1 Answers

2
votes

You need to check wheather the httpd.conf and .htaccess files are set properly.You need to make sure if document root is pointing to the laravels public directory.

Please have a check here