Support the ongoing development of Laravel.io →
Installation Configuration
Last updated 2 years ago.
0

Do you have a route to imgweb2 in router.php? If so please include the snippet that defines the route.

0

THe only thing i have in the routes.php is: Route::get('/', function() { return View::make('hello'); });

0

You have to access only: localhost:8000

0

I'm new at this so how to I create a route to my mainmenu.html page

0

Right so your problem has nothing to do with apache... Everything lives in your app dir. Take a look at the docs on routing. You'll need a route like this to get a response:

Route::get('/imgweb2', function() { return View::make('hello'); });

A more sophisticated implementation would look like this:

Route::get('/imgweb2', "ImageController@index");

where you have a controller named ImageController which lives in app/controllers. The controller would then render and return a view (which would typically live in app/views

Good Luck!

0

please give me an example to get the controller to point to mainmenu.html

0

Sorry man - haven't got the time to type it all up but it's in the docs... look at the views section. Laravel doesn't serve straight HTML docs from the file system... it's all managed through routes, controllers and views (which are blade templates)

0

Please all I need is a kick start. My controller is :

<?php class MainMenuController extends BaseController { public function index() { Route::get('MainMenu', function() { return View::make('MainMenu'); }); } } My route is: Route::get('/imgweb2', "MainMenuController@index"); When I type localhost:8000/imgweb2------I get a blank page but no errors so I must almost be there
0

checkout laracasts, it does have videos to help you kickstart your project.

https://laracasts.com/series/laravel-5-from-scratch/episodes/1

0

Sign in to participate in this thread!

Eventy

Your banner here too?

dendic dendic Joined 30 Dec 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.