<?php

use Illuminate\Support\Facades\Route;
use App\Http\Controllers\EmailController;
use App\Http\Controllers\LanguageController;


/*
|--------------------------------------------------------------------------
| 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('/', function () {
    return view('web.index');
});
//Route::get('/change', [LanguageController::class, 'change'])->name('changeLang');
Route::get('/locale/{locale}', function ($locale) {
    Session::put('locale', $locale);
    return redirect()->back();
})->name('setLocale');
Route::post('/send_email',[EmailController::class,'sendEmail'])->name('send_email');
Route::post('/send_consultation_email',[EmailController::class,'sendConsultationEmail'])->name('send_consultation_email');

