| Q | A
| ------------ | ---
| Bug? | no
| New Feature? | no
| Version | 6.3
$customer = \GuzzleHttp\Client(['base_uri'=>'https://example.com']);
$response = $customer->request('GET', '/', ['query'=> ['name'=>'Dolce| Gabana']]);
All is correct except the parameter of the query is urlencoded
I want exactly this request uri
@alexeyshockov is right, URL encoding should not be a problem. I'm afraid manual instantiation won't help either.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed after 2 weeks if no further activity occurs. Thank you for your contributions.
Most helpful comment
IMO you should not want to do that. The remote server must decode the query string, so it will receive the original string in the end. BTW, it's better to use
queryoption to manage query string parameters.If you want to do it anyway, try to construct an instance of Uri class manually.