0

why always Sorry, the page you are looking for could not be found.

1/1 NotFoundHttpException in compiled.php line 8882:

in compiled.php line 8882 at RouteCollection->match(object(Request)) in compiled.php line 8206 at Router->findRoute(object(Request)) in compiled.php line 8134 at Router->dispatchToRoute(object(Request)) in compiled.php line 8130

and this is my route:

Route::get('/reportpeta/{filterperiode}','PetaReportController@getProvinsi');

view.blade

{{ Form::open(array('url' => url('/reportpeta/'),'method' => 'get')) }}
    ....
{{!! Form::close() !!}}

Controller

public function getProvinsi($filterperiode){
.......
}

and this is problem because calling

{{ Form::open(array('url' => url('/reportpeta/'),'method' => 'get')) }}

please tell me how to call url correctly

1 Answer 1

1

filterperiode is required parameter

Route::get('/reportpeta/{filterperiode}','PetaReportController@getProvinsi');

You can make it optional

Route::get('/reportpeta/{filterperiode?}','PetaReportController@getProvinsi');

Don't miss to make function parameter optional

public function getProvinsi($filterperiode = null)

According to @Ijas Ameenudeen Comment

Sign up to request clarification or add additional context in comments.

14 Comments

thanks for an answer but still is Sorry, the page you are looking for could not be found. 1/1 NotFoundHttpException in compiled.php line 8882: in compiled.php line 8882 at RouteCollection->match(object(Request)) in compiled.php line 8206 at Router->findRoute(object(Request)) in compiled.php line 8134 at Router->dispatchToRoute(object(Request)) in compiled.php line 8130 at Router->dispatch(object(Request)) in compiled.php line 2472
Try php artisan route:list from cmd to get all routes
i have been php artisan route:list and result route in list
@iipmuhamadikbal have you tried second code in above answer ?
@Mahmoud Gamal , maybe im wrong when calling in views.blade {{ Form::open(array('url' => url('/reportpeta/'),'method' => 'get')) }} but i dont know how calling its true
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.