Well, the title may sound a bit weird, but what I am trying to do can be simplified to:
I am adding a comment
I check, if the comment belongs to certain page by using the Route::current()
When creating new, the form send the request to a controller with postAddComment method
This method calls the Tutorial::addComment($comment)
method
In this method, I need to get a Route::current() of the PREVIOUS page (the page i submitted the comment from)
Can somebody please understand (laugh) and help me?
(Also, how the hell can i make a bulleted list here? I guess the Marksomething intepret here is broken as i can't use lists nor code block etc...)
Maybe this is what you are looking for: Redirect::back() ?
psychonetic said:
Maybe this is what you are looking for: Redirect::back() ?
Nope, I need to get the route to the previous page, to save the comment. Then i use the route to the page to load the appropriate comments...
Ok, I solved it by adding <input type="hidden" name="route" value="{{ Request::path(); }}">
to it..
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community