Ad
Using Route() And With() In Html View In Laravel 5.6
For redirection, in controllers, we can write like this:-
Redirect::Route('front_index')->with('RegError', 'An error occured while adding the user.');
How can I set up the href
of an anchor tag so that I can send the 'RegError' too? Say something like this?
<a target="_blank" rel="nofollow noreferrer" href="{{route('front_index')->with('RegError', '')}}">
Ad
Answer
actually you can't because with
function is used to pass parameters from controllers to view and route
helper doesn't have this method.
You need to make request and in controller pass your RegError
Ad
source: stackoverflow.com
Related Questions
- → "failed to open stream" error when executing "migrate:make"
- → October CMS Plugin Routes.php not registering
- → OctoberCMS Migrate Table
- → OctoberCMS Rain User plugin not working or redirecting
- → October CMS Custom Mail Layout
- → October CMS - How to correctly route
- → October CMS - Conditionally Load a Different Page
- → Make a Laravel collection into angular array (octobercms)
- → In OctoberCMS how do you find the hint path?
- → How to register middlewares in OctoberCMS plugin?
- → Validating fileupload(image Dimensions) in Backend Octobercms
- → OctoberCMS Fileupload completely destroys my backend
- → How do I call the value from another backed page form and use it on a component in OctoberCms
Ad