mrkarma4ya
1 month ago
184
3
Laravel

Routes not working in hosted app

Posted 1 month ago by mrkarma4ya

Hello,

My routes work fine on my local machine, but once I upload them in the hosting server, they don't work at all. Only the homepage works.

How can I fix this?

Here's my web.php file:

<?php

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/


Route::get('/', '[email protected]')->name('home');
Route::get('/about', '[email protected]')->name('about');
Route::get('/services', '[email protected]')->name('services');


Route::resource('/posts', 'PostsController');
Route::resource('/comments', 'CommentsController');
Route::resource('/category', 'CategoryController');


Auth::routes();

Route::get('/dashboard', '[email protected]');

Route::get('posts/{id}/duplicate', '[email protected]');
Route::get('/logout', '\App\Http\Controllers\Auth\[email protected]');

Route::get('/dashboard/category/create', '[email protected]');
Route::get('/dashboard/category', '[email protected]_category');
Route::get('/dashboard/posts', '[email protected]_posts');

And here's a link to my hosted app: lekham.ushostserver.com

Please sign in or create an account to participate in this conversation.