Files
karudhaas/routes/web.php
2020-08-14 01:10:55 +05:00

26 lines
731 B
PHP

<?php
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Route;
use App\Article;
/*
|--------------------------------------------------------------------------
| 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('/ogimage', function(Request $request) {
$article = Article::findOrFail($request->query('id'));
return view('ogimage', ['article' => $article]);
});
Route::get('{path}', function () {
return view('app');
})->where('path', '(.*)');