laravelEcomm/routes/web.php
2024-07-07 13:06:31 +05:45

31 lines
1.1 KiB
PHP

<?php
use App\Http\Controllers\MainController;
use Illuminate\Support\Facades\Route;
Route::get('/', [MainController::class, 'index']);
Route::get('/about', [MainController::class, 'about']);
Route::get('/blog', [MainController::class, 'blog']);
Route::get('/blogDetails', [MainController::class, 'blogDetails']);
Route::get('/cart', [MainController::class, 'cart']);
Route::post('/addToCart', [MainController::class, 'addToCart']);
Route::get('/deleteCartItem/{id}', [MainController::class, 'deleteCartItem']);
Route::post('/updateCartItem/{id}', [MainController::class, 'updateCartItem'])->name("cart.update");
Route::get('/checkout', [MainController::class, 'checkout']);
Route::get('/main', [MainController::class, 'main']);
Route::get('/shop', [MainController::class, 'shop']);
Route::get('/single/{id}', [MainController::class, 'singleProduct']);
Route::get('/register', [MainController::class, 'register']);
Route::post('/registerUser', [MainController::class, 'registerUser']);
Route::get('/login', [MainController::class, 'login']);
Route::post('/loginUser', [MainController::class, 'loginUser']);
Route::get('/logout', [MainController::class, 'logout']);