Support the ongoing development of Laravel.io →
Forms Requests
Last updated 2 years ago.
0

How are you trying to access those variables after?

Are you using:

$the_var = Request::get('access_code');
Last updated 2 years ago.
0

I'm redirecting it to external url and have no idea how they are trying to access them. If I post it through view using <form>, I'm getting desired result from the external url, but not when I'm posting through controller using Redirect.

Last updated 2 years ago.
0

Ah if you are redirected to an external then you need to either build a query string and submit the vars VIA query string or you need to use CURL and do an actual post from the server.

Using the query string is a little easier to program.

I think this will work

return Redirect::to($url, array('encRequest'=>$encrypted_data, 'access_code'=>$access_code)) 

basically you want to have http://example.com/?encRequest=blah&access_code=somecode

->with message won't work because it creates an environment variable only available in laravel. When you hit an external server the only way to pass variables is query string or within POST data.

Last updated 2 years ago.
0

If I try your solution, laravel is throwing the below error.

The HTTP status code "1" is not valid

Last updated 2 years ago.
0

Does that come from your server or the remote one?

Last updated 2 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

mahefooz mahefooz Joined 3 Nov 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.