diff --git a/resources/views/mylinkspao.blade.php b/resources/views/mylinkspao.blade.php index 78e0d739..37a17420 100644 --- a/resources/views/mylinkspao.blade.php +++ b/resources/views/mylinkspao.blade.php @@ -26,7 +26,7 @@ let id = formData.get('id'); let action = formData.get('action'); - fetch('{{ url('handle-article-action') }}/id=' + id + '&action=' + action) + fetch('{{ url('handle-article-action-pao') }}/id=' + id + '&action=' + action) .then(response => response.text()) .then(data => { document.getElementById('result').innerHTML = data; diff --git a/routes/web.php b/routes/web.php index 33ec20f8..44d27616 100644 --- a/routes/web.php +++ b/routes/web.php @@ -6217,12 +6217,8 @@ Route::get('/mylinkspao', function () { return view('mylinkspao'); }); -Route::get('/handle-article-action', function (Request $request) { +Route::get('/handle-article-action-pao/{id}/{action}', function ($id, $action) { - - $id = $request->id; - $action = $request->action; - if ($action == 'search') { // Logica di ricerca dell'articolo return "Ricerca articolo con ID: " . $id;